Bulk update Outlook Contacts’ phone numbers to be E.164 compliant

Here’s a quick & dirty tool I put together for Outlook to be able to update all the phone numbers of contacts to make them E.164 compliant. It relates back to a post a while back around the challenges of formatting numbers ‘correctly’, particularly important once you get into using click-to-dial technologies such as Office Communication Server.

The tool itself is basic since it’s only really expected that people will run it once, to sort out the numbers of old contacts you might have. It will check all the contacts in a given folder and automatically fix the numbers up, but there are a few caveats…

  • It’s hard coded for UK numbers beginning +44 … though the code is pretty easy to get to if you know anything about Outlook forms, and you can modify it at will.
  • It doesn’t back up the contacts before modifying, so you might just want to copy your Contacts folder somewhere else before running, if you’re of a nervous disposition. I can verify that it hasn’t mangled any of my contacts and nobody in Microsoft who’s tried it has reported a problem.
  • It’s not exactly straightforward to install – but if you follow the instructions carefully, you’ll be OK.
  • The document in the ZIP file explaining how to install & run it, is in Word 2007 format (docx). If you still haven’t either upgraded or installed the compatibility pack to add OpenXML support to your older version of Office, there’s a link in the ZIP file to go straight to the download page.

A final word: this is completely unsupported, supplied “as is” etc. If it does mangle all your contacts up, just revert to your backup copy – and if you didn’t take a backup then you’ve only got yourself to blame.

Harsh but fair I think 🙂

Enjoy.

The logic converts “from” the format on the left to the format on the right… (_ denotes a space)

Old format number begins New format number begins
0 +44
(0 +44 (
+44_0 +44_
+44(0 +44(
+44 (0) +44
+440 +44
(0) +44_

Examples

old number New number
0118 909 1234 +44118 909 1234
(0118) 909 1234 +44 (118) 909 1234
+44 0118 909 1234 +44 118 909 1234
+44(0118) 909 1234 +44(118) 909 1234
+44 (0)118 909 1234 +44 118 909 1234
+440118 909 1234 +44118 909 1234
(0)118 909 1234 +44 118 909 1234

Leave a Reply

Your email address will not be published. Required fields are marked *