10 G$zCHR$(27>+"K"+CHR$(l00)+CHR(0)
2c3 A$=CHR$( 85 > +(;EW$( 42 >
30B$~~CHR$(42)tCMR$(85)
40 I,PRINT CHR$(27)"1";
50FOR Rr-1 TO 3
60LPRINT G$;
70FOR X=1 TO 50: L,PRINT A$;: NEXT X
80LPRINT
90InPRINT G$;
100 FOR X=1 TO 50: LPRINT B$;: NEXT X
110 LPRINT: NEXT R
120 LPRINT CE<R$(27) "@"
Notice that the first line stores the whole graphics command in a single string variable. In order to do this you must put plus signs between the elements of the command. Once you have done this at the beginning of the program, each time you enter LPRINT G$; you have issued the graphics command. Lines 20 and 30 do the same thing with the data used in this program. As you can see, the use of string variables saves some typing even in this short program. In a long program it can save you much more time and effort.
Graphics and low ASCII codesSending a few of the codes between 0 and 31 with BASIC or another programming language can cause problems on some computer systems. The problem is that most computer systems handle some of these codes in a special way instead of delivering them to the printer.
For example, one computer system handles form feeds by itself. It counts lines to keep track of the top of page. If a program sends the ASCII code for form feed (12) to the printer, the computer system intercepts it and sends instead the code for line feed (10) several times. If you are in a graphics mode with this system and send a 12 to fire pins 3 and 4, the computer system will intercept that 12 and send several 10s instead. You can see how this would ruin your graphics. You would get pins 2 and 4 (whose sum is 10) several times instead of pins 3 and 4 only once.
If your computer system screens out or changes any codes sent to it, you can often design around these problems by using other numbers with similar patterns, and you can see Appendix F for a method to determine which codes may cause problems and for some ideas on overcoming those problems.
89