Applies to: Exchange Server 2007 SP3, Exchange Server
2007 SP2, Exchange Server 2007 SP1, Exchange Server 2007
Topic Last Modified: 2007-08-24
This topic explains how to use the Exchange Management Shell to mail-enable multiple existing contacts in Microsoft Exchange Server 2007. This procedure mail-enables existing contact objects in the Active Directory directory service by populating their Exchange attributes (such as the contact's alias and external e-mail address).
Note: |
---|
This procedure does not create new contacts in Active Directory. |
To mail-enable existing contacts, at a minimum you must provide external e-mail addresses. When mail-enabling several contacts in bulk, it is easier to first export the list of contacts to a .csv file, and then add the external e-mail addresses to the .csv file by using a text editor such as Notepad, or a spreadsheet application such as Microsoft Office Excel. You can then use the updated .csv file in your bulk mail-enabling operation.
Before You Begin
To perform this procedure, the account you use must be delegated the following:
- Exchange Recipient Administrator role
For more information about permissions, delegating roles, and the rights that are required to administer Exchange 2007, see Permission Considerations.
Important: |
---|
If you want to mail-enable existing contacts in a domain that is different than the one in which your Exchange servers reside, you must first prepare that domain for Exchange 2007. To learn more about preparing a domain for Exchange 2007, see How to Prepare Active Directory and Domains. |
Procedure
To use the Exchange Management Shell to mail-enable multiple existing contacts
-
To export the list of existing contacts in your organization that are not mail-enabled to a .csv file, run the following command.
Copy Code Get-Contact | Out-File "C:\ContactsList.CSV"
-
The resulting .csv file will be similar to the following:
Copy Code #TYPE System.Management.Automation.PSCustomObject, Name Kim Abercrombie Don Hall Sanjay Patel Amy Rusko ...
-
For each contact, add a column heading and the external e-mail addresses to the .csv file. The updated .csv file should look similar to the following:
Copy Code #TYPE System.Management.Automation.PSCustomObject, Name,ExternalAddress Kim Abercrombie,Kim@contoso.com Don Hall,Don@fabrikam.com Sanjay Patel,Sanjay@fabrikam.com Amy Rusko,Amy@contoso.com ...
-
To import and use the data in the .csv file so you can mail-enable the contacts in bulk, run the following command.
Copy Code Import-CSV "C:\Contacts.CSV" | ForEach-Object {Enable-MailContact -Identity $_.Name -ExternalEmailAddress $_.ExternalAddress}
For detailed syntax and parameter information, see Get-Contact and Enable-MailContact reference topics.
For More Information
For more information about the Exchange Management Shell, see Using the Exchange Management Shell.
For more information about pipelining in the Exchange Management Shell, see Pipelining.
For more information about exporting data to text files, see Working with Command Output.