Printing Data According To A Previously Defined Format - Commodore CBM Printer 4022 User Manual

Hide thumbs Also See for CBM Printer 4022:
Table of Contents

Advertisement

Example:
OPEN
5,4
PRINT#5,"THIS
IS
A
TEST!"
Results
in:
THIS
IS
fl
TEST!
Printing
Data According
to
a Previously
Defined Format: sa=1
A
secondat7 address
of
1
invokes the formatting
features
of
your
printer.
The
data
to
be
printed
is
arrayed according
to
a previously specified
format using sa=2.
If
you
should
transmit astring
of
data
when
sa=1
is
in
effect
and
there
is
no
formatting data
in
the
printer's
memory,
then
the
data
string
is
printed exactly as
it
is
received.
When
formatting
string
data
from
the
computer,
a
skip,
CHR$(29), must be
sent
to delimit
the
end
of
a
string
being
edited
to
a
field.
Leading
blanks
are stripped
off
a
string;
therefore, to
print
a
blank alpha
field
you must
transmit a
shifted blank,
CHR$(160).
The
alpha
field
is
then
right
padded
with blanks as
shown
below.
Example:
PRINT#1,"AAA
AAA
AAA"
PRINT#2,"ABC"
CHR$(29)
CHRSd
60)
CHR$(29)
"DEF"
Results
in:
ABC
DEF
-22

Advertisement

Table of Contents
loading

Table of Contents