Mail-Enabling a Contact

A mail-enabled contact is a contact that has at least one email address defined within Exchange. A contact cannot have a mailbox because it is not a security principal, so there is no way to safely authenticate the object. You use a mail-enabled contact when you have an email address external to the forest’s Exchange organization that you want to be listed in your GAL. The email address could be external to the company or it could just be external to that forest’s Exchange organization. Examples would be people from other companies or users who do not use the Active Directory of the Exchange organization.

Using a graphical user interface

  1. Open the ADUC snap-in.If you need to change domains, right-click on Active Directory Users and Computers in the left pane, select Connect to Domain, enter the domain name, and click OK.
  2. In the left pane, browse to the parent container of the contact, right-click on the contact, and select Exchange Tasks.
  3. On the Welcome screen, click Next.
  4. Select Establish E-mail Address and click Next.
  5. Verify the mail alias.
  6. Click Modify, select external email address type (generally SMTP Address), and click OK. Enter an external email address and click OK.
  7. Select the associated administrative group and click Next.
  8. On the Completion screen, click Finish.

Using a command-line interface

> exchmbx -b "<ContactDN>" -me <smtp email address>

Replace <ContactDN> with the contact’s distinguished name and the <smtp email address>  with the contact’s external email address.

For an alternative method, create an LDIF file called mailenable_contact.ldf with the following contents:

dn: CN=<ContactDN> 
changetype: modify
replace: targetAddress
targetaddress: SMTP:<smtp email address>
replace: mailNickName
mailNickname: <mail nickname>
replace: mAPIRecipient
mAPIRecipient: FALSE
replace: legacyExchangeDN
legacyExchangeDN: <legacy exchange DN>
replace: internetEncoding
legacyExchangeDN: 1310720

Replace <ContactDN> with the contact’s distinguished name, <smtp email address>   with the contact’s external email addresss, and <legacy exchange DN>  with the proper legacy exchange distinguished name value. Then run the following command:

>ldifde -i -f mailenable_user.ldf

Using VBScript

' This code mail enables a contact.
strContactDN = "<ContactDN>" ' e.g., cn=jsmith,ou=Contacts,dc=rallencorp,dc=com
strEmailAddr = "<EmailAddress>" 'e.g.,
' ------ END CONFIGURATION ---------
set objContact = GetObject("LDAP://" & strContactDN)
objContact.MailEnable strEmailAddr
objContact.Put "internetEncoding",1310720
objContact.SetInfo( )
Wscript.Echo "Successfully mail-enabled contact."