Hi all,
I'm pretty stuck here.. I'm unable to associate a variable with my csv file. I import the csv which has three columns, UserPrincipalName, DisplayName, and NewUserPrincipalName. When I import the CSV attempt to associate the column UserPrincipalName and NewUserPrincipalName
with a variable.
Here is my script so far..
$csv = Import-csv
"F:\temp\user.csv" -Header ("UserPrincipalName",
"DisplayName","NewUserPrincipalName")
ForEach($item
in $csv){
$UPN = $_.UserPrincipalName
$NewUPN = $_.NewUserPrincipalName
Set-MsolUserPrincipalName -UserPrincipalName
$UPN -NewUserPrincipalName
$NewUPN
}