Wednesday, March 7, 2007

Script: Globally Replace Email Domain

Have you ever had to globally replace one email domain with another? Maybe you are in the middle of a merger or possibly made a typo in a recipient policy. Searching for and updating idividual email accounts can be tedious.

I couple of weeks ago a friend had a need for a script to identify accounts with an @domainA.com email address and replace it with an @domainB.com address. Below is the script I created to accomplish such a task.

Sample scripts are provided AS IS without warranty of any kind. The entire risk arising out of the use or performance of the sample scripts and documentation remains with you. In no event shall its authors, or anyone else involved in the creation, production, or delivery of the scripts be liable for any damages.