+ Reply to Thread
Results 1 to 8 of 8

Format phone numbers

  1. #1
    Registered User
    Join Date
    03-18-2011
    Location
    Menen
    MS-Off Ver
    Excel 2010
    Posts
    1

    Format phone numbers

    Hello,

    New here.
    I have to convert a lot of phone numners (eg. +32498871699) into a more readable format (eg. +32 498 87 16 99).

    How can I do this without having to edit all the numbers and add the spaces manually?
    All telephone numbers are stored as text.

    I use Excel 2010 (Dutch version, English language pack available).

    Thanks a lot!

    Filip

  2. #2
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Edit phone numbers

    Are you familiar with the LEFT(), MID() and RIGHT() functions?

    http://www.excelfunctions.net/LeftFunction.html

    http://www.excelfunctions.net/MidFunction.html

    http://www.excelfunctions.net/RightFunction.html

  3. #3
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,425

    Re: Edit phone numbers

    =MID(A2,1,3)&" "&MID(A2,4,3)&" "&MID(A2,7,2)&" "&MID(A2,9,2)&" "&MID(A2,11,2)


    Regards
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  4. #4
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Edit phone numbers

    Or

    =LEFT(A1,3)&" "&MID(A1,4,3)&" "&MID(A1,7,2)&" "&MID(A1,10,2)&" "&RIGHT(A1,2)

  5. #5
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Edit phone numbers

    If you enter the numbers just as numbers rather than text, you can custom-format them as +00 000 00 00 00
    Entia non sunt multiplicanda sine necessitate

  6. #6
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,425

    Re: Edit phone numbers

    @Cutter: I just thought the consistent use of MID throughout was aesthetically pleasing ;-)

    I'm not sure if there's any trade off in efficiency.

    Regards

  7. #7
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Edit phone numbers

    @TMShucks

    You're right - it's very pretty!

    I just thought I should justify the links I provided.

    I doubt there's an efficiency difference.

  8. #8
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,425

    Re: Format phone numbers

    @Cutter: Bless, there you were, going into full coaching mode and encouraging the OP to work it out for him/herself. and I steamed in and blew it out the water. Sorry ;-(

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1