+ Reply to Thread
Results 1 to 6 of 6

add a Zero to a 13 digit number

  1. #1
    Registered User
    Join Date
    05-01-2020
    Location
    Ireland
    MS-Off Ver
    2013
    Posts
    58

    add a Zero to a 13 digit number

    I have a list of these numbers starting in Column B2: such as

    B2
    1092813301968
    1122915351204

    I wish to add a "0" to proceed each value, for it to become a 14 Digit Number
    B2
    01092813301968
    01122915351204

    Thank you for any suggestions

  2. #2
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP and 2007
    Posts
    15,913

    Re: add a Zero to a 13 digit number

    Do you wish the result to be a text string, or do you wish the result to still be a number but be displayed with the leading 0?

    To display a number as 14 digits (with leading 0s when the number is smaller than 1E13) but keep the underlying value as a number, use a number format code like "00000000000000" -- https://support.microsoft.com/en-us/...rs=en-us&ad=us

    To convert a number to text in a specific number format, use the same number format code in a TEXT() function -- https://support.microsoft.com/en-us/...8-93d29371225c =TEXT(B2,"00000000000000")

    Be aware that the number 01092813301968 (even when formatted to display with the leading 0) is not the same as the text string "01092813301968". Users often have other troubles when trying to compare or work with numbers stored as text, so you may want to look into some of those issues so you can avoid them.
    Quote Originally Posted by shg
    Mathematics is the native language of the natural world. Just trying to become literate.

  3. #3
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2406
    Posts
    44,416

    Re: add a Zero to a 13 digit number

    It sort of depends on what you want to happen next... If you want it to look like a 14 digit number...

    then apply a custom format of 00000000000000 to the cells.

    A little more explanation of what happens NEXT to your shiny new 14 digit number might help....
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU

  4. #4
    Registered User
    Join Date
    05-01-2020
    Location
    Ireland
    MS-Off Ver
    2013
    Posts
    58

    Re: add a Zero to a 13 digit number

    The file I received came in an incorrect format, the new improved (preceeding 0) will just be a "Fixed" value

    It affects 1000 values out of 6000 (other values came in correctly and are shorter numbers)..so important to have this value corrected

  5. #5
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.85 (24051214))
    Posts
    8,825

    Re: add a Zero to a 13 digit number

    format the cell
    custom format
    and add 14 zeros
    Wayne
    if my assistance has helped, and only if you wish to , there is an "* Add Reputation" on the left hand side - you can add to my reputation here

    If you have a solution to your thread - Please mark your thread solved do the following: >
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

  6. #6
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2406
    Posts
    44,416

    Re: add a Zero to a 13 digit number

    Post a small sample sheet showing a representative sample of what you have... and what it should look like afterwards. (5 rows, some of 13 digits, some with fewer.. so we know what you expect to see in BOTH cases).

    see yellow banner, top of page, for instructions on posting a sample sheet.

+ 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. [SOLVED] Color a single digit in a mult-digit number cell
    By Phyllis in forum Excel General
    Replies: 8
    Last Post: 09-30-2022, 04:22 PM
  2. Replies: 6
    Last Post: 02-03-2019, 06:05 AM
  3. [SOLVED] Formatting to make 2 digit number show up at 3 digit number.
    By cadamhill in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-18-2012, 06:58 PM
  4. Replies: 4
    Last Post: 09-12-2011, 12:00 PM
  5. [SOLVED] how to identify only 2 digit permuted number from list of 3 digit number
    By bigcrap in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 09-08-2011, 03:06 PM
  6. [SOLVED] how to identify only 3 digit permuted number from list of 4 digit number
    By bigcrap in forum Excel - New Users/Basics
    Replies: 6
    Last Post: 05-10-2011, 11:30 AM
  7. Replies: 2
    Last Post: 06-17-2010, 08:36 PM

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