Add leading Zeros
I want to add leading zeros for a number which is of type character.
Data : w_lan type char12.
w_lan = 4030.00
i want this to be w_lan = 000004030.00
The function modules CONVERSION_EXIT_ALPHA_OUTPUT and CONVERSION_EXIT_ALPHA_INPUT wont work in this case. Suggest some other way .
calculate the string length and loop it and concatenate 0 and the number untill u get the desired status .....
l = strlen(w_lan).
v = 0.
while l < 10.
concatenate v to l into target.
now the value will be stored in the target.