Pos - AMSTRAD cpc 6128 User Instruction

Integrated computer/disc system
Hide thumbs Also See for cpc 6128:
Table of Contents

Advertisement

POS
PO S (
#
<stream expression> )
10 MODE 1:BORDER 0:LOCATE 8,2
20 PRINT "use cursor left/right keys"
30 WINDOW 1,40,12,12:CURSOR 1,1
40 FOR n=1 TO 19:PRIN1 CHR$(9);:NEXT
50 IF INKEY(1)<>-1 THEN PRINT CHR$(9);
60 IF INKEY(8)<>-1 THEN PRINT CHR$(8);
70 LOCATE #1,2,24
80 PRINT #1,"text cursor ";
90 PRINT #1,"horizontal position =";
100 PRINT #1,POS(#0):GOTO 50
run
FUNCTION: Reports the current horizontal PO S ition of the text cursor relative to
the left edge of the text window. The <stream expression> MUST be specified, and does
NOT default to #0.
PO S (
#
8) reports the current horizontal carriage position for the printer, where 1 is
the extreme left hand edge.
PO S (
#
9) reports the logical position in the disc file stream, i.e. the number of
printing characters sent to the stream since the last carriage return.
Associated keywords: V P 0 S, WIN DO W
PRINT
PR I N T [# <stream expression> ,][ <list of: <print items>]
10 a$="small"
20 b$="this is a larger string"
30 PRINT a$;a$
40 PRINT a$,a$
50 PRINT
60 PRINT b$;b$
70 PRINT b$,b$
run
COMMAND: Prints the <list of:<printitem>s to the given stream, (to stream #0 ifno
<stream expression> is specified).
Complete List of Keywords
Chapter 3 Page 59

Advertisement

Table of Contents
loading

Table of Contents