XFA Specification
Chapter 24, Picture Clause Specification
Picture Clause Reference
928
Effect of the
8
Picture Symbol
The
8
picture symbol is used to retain the expressed precision of supplied data after the decimal radix. For
example, suppose the picture clause is being used for output. The following table shows the output for
various picture clauses and input strings:
Picture clause
zzz,zz9.8888
Input value
123456.000
123456.0
123456
Formatted result
123,456.000
123,456.0
123,456
123,456
zzz,zz9.88
123456
Note that when the input number has no decimal point the decimal radix is removed from the formatted
result. The
8
picture symbol is unique in exerting this side-effect.
Effect of the % Picture Symbol
The % picture symbol indicates that the input data is a percentage and ends in the local percentage
symbol. On input the percentage symbol is stripped out and the numeric value is converted to canonical
form by multiplying it by 100. On output the canonical value is divided by 100 and a local percentage
symbol is appended.
Picture clause
zz9%
zzz,zz9.99%
Input value
12%
1,234.5%
Internal (canonical)
value
0.12
12.345
Output value
12%
1,234.50%
Requirements for Acceptable Number Picture Clauses
When the parentheses picture symbols are used in a numeric picture clause, they must be paired, left with
right, and must enclose all occurrences of
9
,
z
, and
Z
picture symbols.
When the
E
picture symbol is used in a numeric picture clause, it must follow all occurrences of the
9
,
z
,
and
Z
picture symbols.
When the
8
picture symbol is used in a numeric picture clause, it must not be intermixed to the right of the
.
picture symbol with either
9
or
Z
picture symbols.
When the
%
picture symbol is used in a numeric picture clause, it must follow all occurrences of the
9, z,
and
Z
picture symbols.
Also, the meaning of an
8
picture symbol to the left of a
.
picture symbol is not defined in this specification.
Example of Output Formatting
The application of picture clauses to numeric data can produce results such as numeric or monetary
values. Consider the following examples. Results have been quoted, so that one can see where spaces
would appear in the formatted value. The quotes are not actually part of the result.
Home Index Bookmark Pages
Pages: Home Index All Pages