changing multiple items in outlook 2003

All the mobile phones at our company was changed. instead of 050-111222 to 050-222222

Is there any way/program to change the contacts that contain 050-111 to 050-222

Who is Participating?
David LeeCommented:
Hi samadeus,

The macro below will make this change for you assuming the number is formatted as shown.  This particular version only fixes the business telephone number, but I could modify it to fix whichever phone number fields you need fixed.  Follow these instructions to use it:

1.  Start Outlook
2.  Click Tools->Macro->Visual Basic Editor
3.  If not already expanded, expand Modules and click on Module1
4.  Copy the code below and paste it into the right-hand pane of the VB Editor
5.  Click the diskette icon on the toolbar to save the changes
6.  Close the VB Editor
7.  Click Tools->Macro->Security
8.  Change the Security Level setting to Medium
9.  Select a contacts folder and run the macro.

Sub FixPhoneNumber()
    Dim olkFolder As Outlook.Items, _
        olkContact As Outlook.ContactItem
    If Application.ActiveExplorer.CurrentFolder.DefaultItemType <> olContactItem Then
        MsgBox "You have to select a folder containing Contacts to run this macro.", vbCritical + vbOKOnly, "FixPhoneNumber Macro"
        Set olkFolder = Application.ActiveExplorer.CurrentFolder.Items
        For Each olkContact In olkFolder
            With olkContact
                If Mid(.BusinessTelephoneNumber, 1, 7) = "050-111" Then
                    .BusinessTelephoneNumber = "050-222" & Mid(.BusinessTelephoneNumber, 8)
                End If
            End With
        MsgBox "All done!", vbInformation + vbOKOnly, "FixPhoneNumber Macro"
    End If
    Set olkContact = Nothing
    Set olkFolder = Nothing
End Sub

Hello samadeus,

you could export your contacts to excel do a search and replace there and import them back into outlook
source: assistance/ha010964221033.aspx
source: assistance/HA010964231033.aspx

hope this helps a bit
samadeusAuthor Commented:
Goof idea.
I have try that but in excel when i am replacing the 111 to 222 it also replace the firs nomber (0) so when i am importing back i have now 50-222222 instead of 050-222222
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

samadeusAuthor Commented:
goof - good
samadeusAuthor Commented:
The table down in the pic shows how it looks like befor i replace
(i have no idea what the nombers ther means- and up you can see how it looks after changing
samadeusAuthor Commented:
Hi BlueDevilFan.

Thanks. i am at my way t owork to try your macro.
BTW I'ts a Mobile Phone, should i just change the "(.BusinessTelephoneNumber, 8)" to mobilephonenomber?
and the exact new didgits that i have to change are "4119" instead of "8676"
David LeeCommented:
Hi, samadeus.

Yes, change ".BusinessTelephoneNumber" to ".MobileTelephoneNumber".  
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.