Exchange 2010 – Create Contacts from CSV

Exchange LogoCreate a CSV file that contains the following columns:

ExternalEmailAddress
Name
Alias
FirstName
LastName
OrganizationalUnit

Then from the Exchange Management Shell run the following command:

Import-CSV C:scriptsMyCSV.csv | ForEach-Object{New-MailContact -ExternalEmailAddress $_.ExternalEmailAddress -Name $_.Name -Alias $_.Alias -FirstName $_.FirstName -LastName $_.LastName -OrganizationalUnit $_.OrganizationalUnit}

Leave Comment

Your email address will not be published. Required fields are marked *