Commodore 128 System Manual page 276

Table of Contents

Advertisement

GETKEY
Receive input data from the keyboard, one character
at a time and wait for a key to be pressed.
GETKEY variable list
The GETKEY statement is very similar to the GET statement.
Unlike the GET statement, GETKEY if there is no character in the
keyboard buffer will wait for the user to type a character on the
keyboard. This lets the computer wait for a single character to be
typed. This statement can be executed only within a program.
EXAMPLE:
10 GETKEY A$
This line waits for a key to be pressed. Typing any key continues
the program.
10 GETKEY A$,B$,C$
This line waits for three alphanumeric characters to be entered
from the keyboard. GETKEY can also be used to READ numeric
keys.
NOTE: GETKEY cannot return a null (empty) character
string.
GET#
Receive input data from a tape, disk or RS232
G ET# file number, variable list
This statement inputs one character at a time from a previously
opened file. Otherwise, it works like the GET statement. This
statement can be executed only within a program.
EXAMPLE:
10 G ET#1,A$
This example receives one character, which is stored in the
variable A$, from file number 1. This example assumes that file 1
was previously opened. See the OPEN and DOPEN statements.
17-34

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

128d

Table of Contents