Home |
Search |
Today's Posts |
#1
![]() |
|||
|
|||
![]()
I have a column of variable length numbers/text (6-12 characters). I need to
place leading zeros in each of the cells to create a standard length of 15 characters. What's the easiest way to do this? |
#2
![]() |
|||
|
|||
![]()
sleect cells or column then pull-down:
Format Cells... Number Custom and enter 000000000000000 in place of general -- Gary's Student "MVPitts" wrote: I have a column of variable length numbers/text (6-12 characters). I need to place leading zeros in each of the cells to create a standard length of 15 characters. What's the easiest way to do this? |
#3
![]() |
|||
|
|||
![]()
MVPitts wrote:
I have a column of variable length numbers/text (6-12 characters). I need to place leading zeros in each of the cells to create a standard length of 15 characters. What's the easiest way to do this? Hi MVPitts, Try : =right(REPT("0",15) & "text" , 15) @+ FxM |
#4
![]() |
|||
|
|||
![]()
=IF(ISTEXT(A1),REPT("0",15-LEN(A1))&A1,TEXT(A1,"000000000000000"))
-- Kind regards, Niek Otten "MVPitts" wrote in message ... I have a column of variable length numbers/text (6-12 characters). I need to place leading zeros in each of the cells to create a standard length of 15 characters. What's the easiest way to do this? |
#5
![]() |
|||
|
|||
![]()
Which, indeed, can be simplified to
=REPT("0",15-LEN(A1))&A1 -- Kind regards, Niek Otten "Niek Otten" wrote in message ... =IF(ISTEXT(A1),REPT("0",15-LEN(A1))&A1,TEXT(A1,"000000000000000")) -- Kind regards, Niek Otten "MVPitts" wrote in message ... I have a column of variable length numbers/text (6-12 characters). I need to place leading zeros in each of the cells to create a standard length of 15 characters. What's the easiest way to do this? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
leading zeros are not showing in the formula bar but do show in ce | Excel Discussion (Misc queries) | |||
Leading Zeros with a twist. | Excel Discussion (Misc queries) | |||
How do I eliminate leading zeros from downloaded data? | Excel Worksheet Functions | |||
Graph with variable data length | Excel Discussion (Misc queries) | |||
How do I display leading zeros so I can export a fixed in Excel? | Excel Discussion (Misc queries) |