+ Reply to Thread
Results 1 to 10 of 10

How do I format numbers to put a comma after every 4 digits

  1. #1
    Registered User
    Join Date
    10-15-2013
    Location
    Lakewood,NJ
    MS-Off Ver
    Excel 2010
    Posts
    2

    How do I format numbers to put a comma after every 4 digits

    I need to list 4 digit numbers in each section followed by commas, but whatever i do it goes to 3digits (eg. I need "1234,5678,9123" and as soon as I hit Enter it goes to "123,456,789,123"). It wont help to format as text because I have a whole bunch of 12 digit numbers to break up into 4.

  2. #2
    Valued Forum Contributor
    Join Date
    10-26-2008
    Location
    Birmingham, UK
    MS-Off Ver
    All versions up to 2010
    Posts
    1,025

    Re: How do I format numbers to put a comma after every 4 digits

    Hi
    Not sure if this will help but if you format your number in cell A1 to text initially. Then in B1 use this formula it will display as you are asking:

    =MID(A1,1,4)&","&MID(A1,5,4)&","&MID(A1,9,4)

    Once you have done that you can copy column B and choose paste value in the same column which will display as you want.
    Good luck.
    Tony

  3. #3
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,443

    Re: How do I format numbers to put a comma after every 4 digits

    Perhaps custom format as ###,###,###,###

  4. #4
    Registered User
    Join Date
    10-15-2013
    Location
    Lakewood,NJ
    MS-Off Ver
    Excel 2010
    Posts
    2

    Re: How do I format numbers to put a comma after every 4 digits

    @pepe Le Mokko, I need every 4 digits that only helps for 3 digits
    @argk I dont understand

  5. #5
    Valued Forum Contributor
    Join Date
    10-26-2008
    Location
    Birmingham, UK
    MS-Off Ver
    All versions up to 2010
    Posts
    1,025

    Re: How do I format numbers to put a comma after every 4 digits

    Hi
    Format cell A1 as text.
    Enter a 12 digit number in A1.
    Put the formula in cell B1.
    The number is now displayed in your requested format.
    Tony

  6. #6
    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: How do I format numbers to put a comma after every 4 digits

    Format as #\,####\,####

    It's not perfect:

    A
    1
    1234,5678,9123
    2
    123,4567,8912
    3
    12,3456,7891
    4
    1,2345,6789
    5
    ,1234,5678
    6
    ,123,4567
    7
    ,12,3456
    8
    ,1,2345
    9
    ,,1234
    10
    ,,123
    11
    ,,12
    12
    ,,1
    Entia non sunt multiplicanda sine necessitate

  7. #7
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,604

    Re: How do I format numbers to put a comma after every 4 digits

    If they are always 12-digit numbers then you can use this in B1:

    =LEFT(A1,4)&","&MID(A1,5,4)&","&RIGHT(A1,4)

    and copy down.

    Hope this helps.

    Pete

  8. #8
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,443

    Re: How do I format numbers to put a comma after every 4 digits

    [QUOTE=Itstaken1;3439009]@pepe Le Mokko, I need every 4 digits that only helps for 3 digits
    Well then ####,####,####

  9. #9
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,604

    Re: How do I format numbers to put a comma after every 4 digits

    @Pepe,

    No, that doesn't work.

    Pete

  10. #10
    Valued Forum Contributor
    Join Date
    10-26-2008
    Location
    Birmingham, UK
    MS-Off Ver
    All versions up to 2010
    Posts
    1,025

    Re: How do I format numbers to put a comma after every 4 digits

    Hi
    See sample using the solution I provided earlier.
    Hope this helps.
    Good luck.
    Tony
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 8
    Last Post: 01-17-2024, 11:32 AM
  2. problem with converting numbers to TEXT format and applying comma style
    By Vogelmann in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 10-23-2012, 10:43 AM
  3. numbers with `comma style` in text format
    By Vogelmann in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-22-2012, 11:37 AM
  4. Digits after the comma in Userform
    By Gert-Jan in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 07-04-2006, 08:55 AM
  5. Digits in text cannot format as Numbers ?
    By st24961 in forum Excel General
    Replies: 3
    Last Post: 05-31-2005, 01:45 AM

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