Forum Discussion
WelshViking
May 15, 2019Brass Contributor
Teams user info automation
I am hoping someone can provide me with some info.
I want to be able to run a script that allows me to assign the following to multiple users replacing each user identity and tel number with what ever is assigned in one go.
Set-CsUser -Identity User@*****.co.uk -EnterpriseVoiceEnabled $true -OnPremLineURI tel:********
I am assuming i will need a .csv file but how would I then set out the csv to input the correct data?
Noob question... sorry... :)
Assuming you have a blabla.csv with the Identity column designating the user and the Telephone column designating the number, this should do:
Import-CSV blabla.csv | % { Set-CsUser -Identity $_.Identity -EnterpriseVoiceEnabled $true -OnPremLineURI $_.Telephone }
Assuming you have a blabla.csv with the Identity column designating the user and the Telephone column designating the number, this should do:
Import-CSV blabla.csv | % { Set-CsUser -Identity $_.Identity -EnterpriseVoiceEnabled $true -OnPremLineURI $_.Telephone }