Archie
Member
I have a simple problem, but a simple solution eludes me.
I need to generate a string with the last 5 digits being serialized each time the string is generated. For expample:
BYPASSED000000A0000001
BYPASSED000000A0000002
BYPASSED000000A0000003
.
.
BYPASSED000000A0009999
The string always has to be the same length. I've started with a string for the first group of fixed characters. I am using a counter to generate the serial number. I use AIC instruction to convert the counter value into a string. If I use ACN to concatenate the two strings, the length will vary because AIC does not create leading 0's.
I have a solution, but it seems like a long way around a simple format instruction to put in leading 0's. Am I missing an easy way to do this?
I need to generate a string with the last 5 digits being serialized each time the string is generated. For expample:
BYPASSED000000A0000001
BYPASSED000000A0000002
BYPASSED000000A0000003
.
.
BYPASSED000000A0009999
The string always has to be the same length. I've started with a string for the first group of fixed characters. I am using a counter to generate the serial number. I use AIC instruction to convert the counter value into a string. If I use ACN to concatenate the two strings, the length will vary because AIC does not create leading 0's.
I have a solution, but it seems like a long way around a simple format instruction to put in leading 0's. Am I missing an easy way to do this?