I have a column of project numbers that vary in length. My plan is to write an IF statement to check the length of the Project Number and pad these numbers with 0 so that the formats are the same, max length of 10, if needed.
<tbody>
</tbody>
I'm using the MID & Format functions to find the location to start padding but it's not working for me.
Using the code above will give a result of 3 and 0000012 for the 2 examples above.
I'm using the PowerPivot plugin for Excel 2010 (version 11.0.5058.0). I appreciate the help!
Current Project Number | New Proj Num |
PRJ3 | PRJ0000003 |
PRJ0000012 | PRJ0000012 |
<tbody>
</tbody>
I'm using the MID & Format functions to find the location to start padding but it's not working for me.
Code:
=FORMAT(MID([ProjectNumber],4,len([ProjectNumber])),"0000000")
Using the code above will give a result of 3 and 0000012 for the 2 examples above.
I'm using the PowerPivot plugin for Excel 2010 (version 11.0.5058.0). I appreciate the help!