Quantcast
Channel: Exchange Server 2013 - General Discussion forum
Viewing all articles
Browse latest Browse all 4521

Edit Bulk Mail Contacts

$
0
0

Hi, l am trying to remove additional SMTP addresses in bulk from Mail contacts in 2010 with the script below.

$list = import-csv d:\support\contacts.csv
foreach($Contact in $list)
{
   $Contact.EmailAddresses |
   ?{$_.AddressString -like "@DOMAINNAME"} | %{
         Set-MailContact $Contact -EmailAddresses @{remove=$_}
    }
}

Contents of the contacts.CSV: has a header of Contact and list of External Email Addresses. 


Viewing all articles
Browse latest Browse all 4521

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>