Mass change contacts mail server

Posted on 2008-11-19
Last Modified: 2012-08-13
I have three state clients that are getting new mail server address changes. Their mail server is changing from to Being  state enitites they have massive amounts of addresses in their contact folders. Is their a simple tool that can make these changes and minimize the pain (whining)? About 200 persons involved in this and each has several hundred contacts with the old extension
Question by:warsawtech
    LVL 59

    Accepted Solution

    The following snippet looks for all contacts with and replaces with

    Replacing @fred with your required domain should do the job for you ... but ask if you need help.

    It is an outlook macro:
    To Create a macro:

    Alt + F11 to open the macro editor
         Insert | Module to insert a code module into the project
         In the project tree select the module.
         Insert the required macro(s) into the selected module, ('Module1' or similar)
    Close the Visual Basic Editor.

    Check Security as appropriate:

    In the application select Tools | Macro | Security
    Select Medium
    Select OK

    To run a macro:

    Alt + F8
    Select the macro
    Select 'Run'

    Sub update_Contacts()
    Dim con As ContactItem
    Dim addy As Object
        For Each con In Application.GetNamespace("MAPI").GetDefaultFolder(olFolderContacts).Items
            con.Email1Address = Replace(con.Email1Address, "", "")
            con.Email1DisplayName = Replace(con.Email1DisplayName, "", "")
            con.Email2Address = Replace(con.Email2Address, "", "")
            con.Email2DisplayName = Replace(con.Email2DisplayName, "", "")
            con.Email3Address = Replace(con.Email3Address, "", "")
            con.Email3DisplayName = Replace(con.Email3DisplayName, "", "")
    End Sub

    Open in new window

    LVL 2

    Author Closing Comment

    Thanks....a dream come true!!!!
    LVL 59

    Expert Comment

    by:Chris Bottomley
    Glad to have been of help, and thanks for the grade.


    Featured Post

    How to improve team productivity

    Quip adds documents, spreadsheets, and tasklists to your Slack experience
    - Elevate ideas to Quip docs
    - Share Quip docs in Slack
    - Get notified of changes to your docs
    - Available on iOS/Android/Desktop/Web
    - Online/Offline

    Join & Write a Comment

    Learn more about the importance of email disclaimers with our top 10 email disclaimer DOs and DON’Ts.
    Granting full access permission allows users to access mailboxes present in their database. By giving full access permission one can open and read the content of any mailbox but cannot send emails from that mailbox.
    Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
    To add imagery to an HTML email signature, you have two options available to you. You can either add a logo/image by embedding it directly into the signature or hosting it externally and linking to it. The vast majority of email clients display l…

    745 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    14 Experts available now in Live!

    Get 1:1 Help Now