Forum Discussion
akadd90
Jan 17, 2022Copper Contributor
convert numbers to text and maitain number of digits including preceeding zeros
HI I need to convert a column of numbers containing three digits (ie 001, 002, 003) into text, and maintain the zeros preceding the the non-zero digits. How can I do this? OR I have two columns...
HansVogelaar
Jan 17, 2022MVP
If column A and column B contain text values, use
=A2&B2
in C2 and fill down. But if they contain numbers with custom number formats "00" and "000" respectively, use
=TEXT(A2,"00")&TEXT(B2,"000")
akadd90
Jan 17, 2022Copper Contributor
This does not work-- puts all the zeros at the front and the nonzero digits at the end
col A col B output desired output
01 001 00011 01001
col A col B output desired output
01 001 00011 01001
- HansVogelaarJan 17, 2022MVP
Could you attach a small sample workbook?