GreenBoy
New member
- Joined
- Apr 13, 2015
- Messages
- 26
- Reaction score
- 0
- Points
- 0
- Excel Version(s)
- Office 365
Im having a very long week and i think my brain needs re-booting.
I know this should be fairly easy but for the life of me i cant get this to work.
I have a series of site numbers which range from 1 to 5 digits in length - i.e. 1 to 99999
What i need to do is make them all 6 digits long and start with a 4, so 1 would become 400001 and 175 would be 400175 all the way up to 499999
Can any kind person point me at the right functions to do this?
I am assuming Text.PadStart is used but need to calc the number of zeros needed and then do the same for a single number 4 at the start, but the calculating the number of Zeros to add to dynamically add a different amount per site number is escaping me.
Thanks in advance for any assistance, comments etc
Dave
I know this should be fairly easy but for the life of me i cant get this to work.
I have a series of site numbers which range from 1 to 5 digits in length - i.e. 1 to 99999
What i need to do is make them all 6 digits long and start with a 4, so 1 would become 400001 and 175 would be 400175 all the way up to 499999
Can any kind person point me at the right functions to do this?
I am assuming Text.PadStart is used but need to calc the number of zeros needed and then do the same for a single number 4 at the start, but the calculating the number of Zeros to add to dynamically add a different amount per site number is escaping me.
Thanks in advance for any assistance, comments etc
Dave