DaveWortley
04-09-2008, 10:34 AM
I have a variable with an integer value, but i want to use this as a string with a zero in front of it.... eg...
v = 1
textbox.text = v
output is "1"
I want this to be "01", there is of course easy way round this = "0" + V but don't want it to then become 010, 011, 012 i want to limit to 2 numbers, without having to do a if v < 10 test.
In VB you could do it with Format() function, but had a look through the Maxscript guide and can't find anything that helps me with this issue.
I'm sure there is an easy solution i'm missing.
v = 1
textbox.text = v
output is "1"
I want this to be "01", there is of course easy way round this = "0" + V but don't want it to then become 010, 011, 012 i want to limit to 2 numbers, without having to do a if v < 10 test.
In VB you could do it with Format() function, but had a look through the Maxscript guide and can't find anything that helps me with this issue.
I'm sure there is an easy solution i'm missing.
