Is there a formula that will automatically add zeros in front of numbers added to a cell?
Is it possible to have this number show, 000000065145, while only typing in 65145? I need to have seven leading zeros before the number.
Best Answers
-
Hi @bcfish ,
You can add a helper column to contain the string with 7 leading 0s. You'll enter the number in another column [number].
The column formula in the helper column will be:
="0000000"+[number]@row
Make sense?
Mark
I'm grateful for your "Vote Up" or "Insightful". Thank you for contributing to the Community.
-
Hi @bcfish
I hope you're well and safe!
To add to Mark's excellent advice/answer.
The number will be converted to text because of the zeros before the original number, but it should work as long as you don't use it for any calculations or similar.
I hope that helps!
Be safe and have a fantastic weekend!
Best,
Andrée Starå | Workflow Consultant / CEO @ WORK BOLD
✅Did my post(s) help or answer your question or solve your problem? Please support the Community by marking it Insightful/Vote Up or/and as the accepted answer. It will make it easier for others to find a solution or help to answer!
SMARTSHEET EXPERT CONSULTANT & PARTNER
Andrée Starå | Workflow Consultant / CEO @ WORK BOLD
W: www.workbold.com | E:andree@workbold.com | P: +46 (0) - 72 - 510 99 35
Feel free to contact me for help with Smartsheet, integrations, general workflow advice, or anything else.
Answers
-
Hi @bcfish ,
You can add a helper column to contain the string with 7 leading 0s. You'll enter the number in another column [number].
The column formula in the helper column will be:
="0000000"+[number]@row
Make sense?
Mark
I'm grateful for your "Vote Up" or "Insightful". Thank you for contributing to the Community.
-
Hi @bcfish
I hope you're well and safe!
To add to Mark's excellent advice/answer.
The number will be converted to text because of the zeros before the original number, but it should work as long as you don't use it for any calculations or similar.
I hope that helps!
Be safe and have a fantastic weekend!
Best,
Andrée Starå | Workflow Consultant / CEO @ WORK BOLD
✅Did my post(s) help or answer your question or solve your problem? Please support the Community by marking it Insightful/Vote Up or/and as the accepted answer. It will make it easier for others to find a solution or help to answer!
SMARTSHEET EXPERT CONSULTANT & PARTNER
Andrée Starå | Workflow Consultant / CEO @ WORK BOLD
W: www.workbold.com | E:andree@workbold.com | P: +46 (0) - 72 - 510 99 35
Feel free to contact me for help with Smartsheet, integrations, general workflow advice, or anything else.
-
similarly I don't use the helper column but write it into the formula
=right("000"+[column A]@row,3)
- 1 becomes 0001 becomes 001
- 41 becomes 00041 becomes 041
- 241 becomes 000241 becomes 241
** be aware of your max digits if you have potential for a number to be larger than the leading zeros you accounted for.
- 5241 becomes 0005241 becomes 241
you would have to up the formula to accommodate
=right("000"+[column A]@row,4)
- 5241 becomes 0005241 becomes 5241
or
=right("0000"+[column A]@row,4)
- 5241 becomes 00005241 becomes 5241
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 64.9K Get Help
- 441 Global Discussions
- 139 Industry Talk
- 471 Announcements
- 4.9K Ideas & Feature Requests
- 129 Brandfolder
- 148 Just for fun
- 68 Community Job Board
- 496 Show & Tell
- 33 Member Spotlight
- 2 SmartStories
- 300 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!