TRS-80
MODEL III
PRINT USING
string; item list
This statement allows you to specify a format for printing string and numeric
values. It can be used in many applications such as printing report headings,
accounting reports, checks, or wherever
a
specific print format is required.
The PRINT
USING
statement
uses
the
following
format:
PRINT USING string
;
value
String and value may be expressed as variables or constants. This statement will
print
the expression contained in the string, inserting the numeric value shown to
the right of the semicolon as specified
by
the field specifiers.
The following field specifiers may
be used
in the string:
#
This sign
specifies the position of
each digit located in the
numeric value. The number of
#
signs you use establishes the
numeric field . If the numeric field is greater than the number
of digits in the numeric value, then the unused field positions
to the left of the number will be displayed as spaces and
those to the right of the decimal point
will
be displayed as
zeros.
The decimal point can be placed anywhere in the numeric
field established
by
the
#
sign. Rounding-off will take place
when digits
to the
right
of
the decimal point are suppressed.
,
The comma
—
when placed in any position between the first
digit and the decimal point
—
will
display
acomma
to
the
left
of every
third
digit
as required.
The
comma
establishes
an
additional
position in the field.
**
Two asterisks placed at the beginning of the field will cause all
unused positions
to
the left of the decimal to be filled with
asterisks. The two asterisks will establish two more positions
in the field.
$
A dollar-sign will be printed ahead of the number.
$$
Two dollar signs placed at the
beginning of the field will act
as
a
floating dollar sign. That
is, it will occupy the first position
preceding the number.'
**$
If these three signs are used at the
beginning
of
the field, then
the vacant positions to the left
of
the
number will
be
filled
by
the
*
sign and the
$
sign will
again position itself in the first
position preceding the
number.
QD
QD
CD
®
Causes
the number to be printed in exponential (E or D) format.
or
1
1 1
1
This will
be displayed as a
"
[
"
.
136