Enform Plus Reference Manual

Clauses
Enform Plus Reference Manual422684-001
5-18
Decorations
pair-of-symbols
are the standard and substitute symbols enclosed within apostrophes (‘ ’). The
standard symbol must appear first, followed by the substitute symbol.
The symbol substitution modifier allows you to replace the standard symbols used in
edit descriptors. You can change the symbols for 9, Z, V, ., and , in the mask (M) edit
descriptor or change the symbol for decimal point (.) in the fixed-point (F) edit
descriptor.
The symbol substitution modifier is useful when you need to specify a character string,
that is also a standard mask symbol. An example would be 9 in a mask for a date. See
the last of the following examples.
The following examples show the effect of the symbol substitution modifier:
Format Item Value Printed Item
------ ---------- ------------
"[SS'.:'] F6.2" 12.45 12:45
"[SS'.:'] M<ZZZ.99>" 12.45 12:45
"[SS'.,'] F10.2" 12345.67 12345,67
"[SS'9X'] M<XX/XX/XXXX>" 10311979 10/31/1999
Decorations
Decorations specify character strings that can be printed along with the value of a
target-item or by-item. Decorations also specify the conditions under which the
character string is added, the location at which the character string is added, and whether
the character string is added before normal formatting is done or after it is completed.
The syntax of a decoration is:
condition
is one or more of the following:
condition location char-string
M
Add char-string if value is negative.
N
Add char-string if value is null.
P
Add char-string if value is positive.
Z
Add char-string if value is zero.
O
Add char-string if overflow condition occurs.