Download Print this page

Epson MX-80 User Manual page 60

Hide thumbs Also See for MX-80:

Advertisement

Chapter 9
Vertical Tabs
Vertical TABS are similar to Horizontal ones. While we can get to any line on the
paper by using enough LPRINTs, VTABs can simplify programming.
Replace the current program with this NEW one:
1 0 L P R I N T C H R $ ( 2 7 ) " C "
C H R $ ( 3 3 ) ;
2 0 L P R I N T C H R $ ( 2 7 ) " B "
C H R $ ( 1 3 8 )
CHR$ ( 1 4 8)
CHR$ ( 1 2 8 ) ;
3 0 L P R I N T
" V E R T I C A L "
C H R $ ( 1 3 9 ) " TABS"
C H R $ ( 1 3 9 ) " W O R K "
4 0 L P R I N T C H R $ ( 1 4 0 ) ;
: GOTO 2 0
and RUN
Smooth as silk. The explanation of how the program works is almost as simple:
Line 10 sets for form length at 33 lines.
Line 20 Esc"B" opens the door to receive V TABs
Line 20 sets Vert TABs at 10 (10+1 28) and 20 (20+128)
Line 20 closes the TAB door with a null 0. (0+128).
Line 30 prints "VERTICAL", TABs down to the 10th line and prints, TABs
down to 20 and prints. CHRS( 139) is the TAB " k e y "
Line 40 sends the Form Feed and keeps the loop closed.
Note the semicolons at the end of the commands in lines 10,20 and 40. Without
them we would slip a line here and there. The Printer will count every LF, but
unless we are printing on a form requiring every line to be positioned just so, we
would miss one now and then.
Did you notice that use of Vertical TABs sends the paper upward in a nice
smooth flow? If we did the same, thing in BASIC with LPRINTs, the paper would
move jerkily as each Line Feed was executed.
Carefully and properly done, Vertical TABs combined with Form Feeds are very
powerful programming tools for business applications.
Q i
62

Advertisement

loading