User Profile
Pol18
Copper Contributor
Joined 2 years ago
User Widgets
Recent Discussions
Re: MS Microsoft Graph PowerShell SDK to assign licenses in bulk from a csv file
Hi Andres Bohren, Can you help me to convert my script to the new version $userName = "SampleUsername" $password = "Password" $securePassword = ConvertTo-SecureString -String $password -AsPlainText -Force $credential = New-Object -TypeName System.Management.Automation.PSCredential -ArgumentList $userName, $securePassword Connect-MsolService -Credential $credential $users = Import-Csv D:\O365\bulk2.csv Import-Csv -Path D:\O365\bulk2.csv | ForEach-Object {New-MsolUser -DisplayName $_.DisplayName -FirstName $_.FirstName -LastName $_.LastName -UserPrincipalName $_.UserPrincipalName -LicenseAssignment $_.AccountSkuId -Password $_.Password -UsageLocation $_.UsageLocation } I'm not really good with this kind of script, I really appreciate if you can help me 🙂 Thanks! Pol16KViews0likes1Comment
Groups
Recent Blog Articles
No content to show