This function is retained only for compatibility. New code should not use it. KbdGetConsole is the preferred function for new code.
The contents and ending condition depend on the keyboard state:
ASCII
The maximum buffer length is 255 bytes.
The character strings can be optionally echoed on the display if echo mode is set. When echo is on, each character is echoed as it is read from the keyboard. Echo mode and binary mode are mutually exclusive. See KbdGetStatus and KbdSetStatus for more information.
The default input mode is ASCII. In ASCII mode, 2-byte character codes only return in complete form. An extended ASCII code is returned in a 2-byte string. The first byte is 0DH or E0H and the next byte is an extended code.
In input mode (binary or ASCII), the following returns can be set and retrieved with KbdGetStatus and KbdSetStatus:
Turnaround Character Echo Mode
Interim Character Flag
Shift State
The received input length is also used by the KbdStringIn line edit functions for re-displaying and entering a caller-specified string. On the next KbdStringIn call the received input length indicates the length of the input buffer that can be recalled by the user using the line-editing keys. A value of 0 inhibits the line-editing function for the current KbdStringIn request.