HP Data Entry and Forms Management System (VPLUS) Reference Manual (32209-90024)
216 Chapter5
Reformatting Specifications
Output Field Menu
NUMn\or
\NUM
Conversion and Movement: Strip any commas, sign, or leading zeros. Float any
minus sign to position preceding the first nonblank character. Right justify data
in the output field. If the data is shorter than the field, pad with blanks on the
left. If the data is too long, strip leading blanks one at a time until data fits. If,
after all blanks are removed, the data is still too long, strip trailing fractional
zeros, one by one. Then, if necessary, round fractional digits, one place at a time,
until the value fits in the output field. (Note that rounding may change the value
of the integer part.) If the value still does not fit, issue error message.
Assume value with length=10 1,234.510
moved to NUM3 field, length=10 ∆∆1234.510
to NUM3 field, length=ll ∆∆∆1234.510
to NUM3 field, length=6 1234.5
to NUM3 field, length=4 1235
to NUM3 field, length=3 ERROR
Assume signed value, length=10 +1234.510∆
moved to NUM2 field, length=10 ∆∆∆1234.51
to NUM2 field, length=3 ERROR
Assume signed value, length=7 -12.10∆
moved to NUM2 field, length=7 ∆-12.10
to NUM2 field, length=3 -12
to NUM2 field, length=2 ERROR
IMPn Conversion and Movement: Strip any decimal indicator, commas, sign, or leading
zeros. Float any minus sign to the position preceding the first nonblank digit.
Right justify data in the output field. If the data is shorter than the field, pad
with blanks on the left. If the data is too long, strip leading blanks, one by one. If
the data does not fit and only the fractional part remains, strip leading fractional
zeros. (Trailing fractional zeros are never stripped from an IMPn field.) If the
data still does not fit, issue error message.
Assume a value, length=10 -123.0120∆∆
moved to IMP4 field, length=10 ∆∆∆-1230120
to IMP4 field, length=8 -1230120
to IMP4 field, length=7 ERROR
Assume a value, length=7 .0120∆∆
to IMP4 field, length=3 120
to IMP4 field, length=2 ERROR
Table 5-2. Standard Formatting by Data Types
Destination
Data Type
Standard Formatting