Specifications

Chapter 15. Function Reference
362
Syntax:
Syntax 1 (Reading from the keyboard):
INPUT$(numcharas)
Syntax 2 (Reading from a device file):
INPUT$(numcharas,[#]filenumber)
Parameter:
numcharas
A numeric expression which returns a value from 1 to 255.
filenumber
A numeric expression which returns a value from 1 to 16.
Description:
INPUT$ reads the number of characters specified by numcharas from the key-
board or from a device file specified by filenumber, then returns the resulting
string.
Syntax 1 (without specification of
filenumber)
INPUT$ reads a string or control codes from the keyboard.
INPUT$ does not echo back read characters on the LCD screen.
The cursor shape (invisible, underlined, or full block) depends upon the specifica-
tion selected by the
LOCATE statement.
The cursor size depends upon the screen mode (single-byte ANK mode or two-
byte Kanji mode), the screen font size (standard-size or small-size), and the char-
acter enlargement attribute (regular-size, double-width, double-height, or quadru-
ple-size). For details about the cursor, refer to Chapter 7, Subsection 7.1.3.
If any key previously specified for keystroke trapping is pressed during execution
of the
INPUT$, then the keyboard input will be ignored; that is, neither typed data
is read by INPUT$ nor keystroke is trapped.
Syntax 2 (with specification of
filenumber)
INPUT$ reads from a device file (the bar code device file or any of the communica-
tions device files).
The number of characters in a device file can be indicated by using a
LOC func-
tion.
INPUT File I/O function
INPUT$
Returns a specified number of characters read from the keyboard or from a device file.