create a contact object from csv file exchange 2007
im creating one by one the contact object in the user and group i got something call external-contact and there another section for some compagny.
August 13th, 2011 9:48am
Hi,
Run the cmdlet with OrganizationalUnit
New-MailContact -Name "Ted Bremer" -FirstName "Ted" -LastName "Bremer"-ExternalEmailAddress
ted@tailspintoys.com -OrganizationalUnit 'OU=new group OU=external-contact,DC=mydomain,DC=com'
> what about if i have to creat a user without email address for now
No, you can't just create a AD user via EMS.Please remember to click Mark as Answer on the post that helps you, and to click Unmark as Answer if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.
Free Windows Admin Tool Kit Click here and download it now
August 13th, 2011 8:45pm
Hi,
What do you mean " i got something call external-contact and there another section
for some compagny."?
To create a new contact via cmdlet, you can do like that:
New-MailContact -Name "Ted Bremer" -FirstName "Ted" -LastName "Bremer"
-ExternalEmailAddress ted@tailspintoys.com
All the attributes you can set have been listed in the link below:
http://technet.microsoft.com/en-us/library/bb124519(EXCHG.80).aspx
Please remember to click Mark as Answer on the post that helps you, and to click Unmark as Answer if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.
August 13th, 2011 9:47pm
i got my domain
lets call it mydomain.com
then an OU call external-contacts and under this i have a compagny name
i want tro create it there
also what about if i have to creat a user without email address for now
Thanks
Free Windows Admin Tool Kit Click here and download it now
August 13th, 2011 10:36pm
i have like 100 contact object to import /create in my domain:
mydomain.com/external-contact/new group
i have there firstname,surname email address and country
how can i do this from powershell command ?
Thanks
August 13th, 2011 11:34pm
Here is an example on how you can create them using a script
$data = Import-Csv .\Contacts-orginal.csv
foreach ($row in $data) {
$Alias = $row.Alias
$Name = $row.Name
$EmailAddress = $row.EmailAddress
$PrimarySmtpAddress = $row.PrimarySmtpAddress
$Description = $row.Description
$ExternalSmtpAddress = $row.ExternalSmtpAddress
New-MailContact -Name $Name -Alias $Alias -ExternalEmailAddress $ExternalSmtpAddress -OrganizationalUnit 'OU=Target,DC=target,DC=local'
Set-Contact -Identity $Alias -Notes $Description
}Jonas Andersson | Microsoft Community Contributor Award 2011 | MCITP: EMA 2007/2010 | Blog:
http://www.testlabs.se/blog | Follow me on twitter:
jonand82
Free Windows Admin Tool Kit Click here and download it now
August 14th, 2011 3:16am
Hi,
This should help:
http://social.technet.microsoft.com/forums/en-us/ITCG/thread/4FCECED2-B2E2-4650-9AB9-F50CD17C6338
Leif
August 14th, 2011 4:05am