Having a problem with ConvertToString

i am creating a positional flatfile from 830 EDI using WMEdi package.
i have created Flatile template(positional) as it says in userguide.
first i am creating Flatile reocrd.
in this record one of record has rightjustifed elements(example… say quantity = 3. i need to rightjustiy(5) this field .so now this value is 3(5 spaces beore).
i can see that in Flatile record these field are right justifed(as i wanted).
but when i am creating srting using convertToString service , the output string does not place these fields as right justified.
i am passing the FFrec, and template obj inputs to the convertToString service.it is not putting these spaces beore these fileds.

can somebody tell me how can solve this problem.


Hello Rao,
You need to pad the field with Zeros whenever you need to right justify the field.

Try to contact wm tech support they will provide some fix to ConvertToString service for the parameter (spacePad) which will have “donttrim” value in that check list.Finally it should result you having leading and trailing spaces as per the template positional.

since convertToString internally do some sort of Trimming before converting file to string.

Generally this fix was provided on our request for wmEDI 4.6 module ,not sure about 6.01.i believe you are using that…