Boggula Srinivas wrote:
Hi All,
I have a display field with 8 field numeric length after user enters the data, i want to prefix two zeros in front of it how will i do it in RPGIV.

If you just want to eliminate zero-blanking, and it's always going to be non-negative, the easiest way would be to set up a data structure with a zoned field overlaid on an alphanumeric field of the same length, Z-ADD your number into the zoned field, then use the alpha field.

Or in a display file, specify the edit code for your field as (if memory serves correctly) "N".

If, on the other hand, you want to always have exactly two leading zeroes, regardless of the number of digits that would display with zero-blanking, it gets more complicated.


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.