KEYBOARD

From Recital Documentation Wiki
Jump to: navigation, search

Purpose

Put characters into the terminal input buffer


Syntax

KEYBOARD <expC>

[CLEAR]


See Also

CHR(), CTRL(), Function Keys, INKEY(), LASTKEY(), MENU(), REPLAY, SET CAPTURE, SET FUNCTION, SET KEY,SET PCKEYS


Description

The KEYBOARD command can be used to 'stuff' characters, <expC>, into the terminal input buffer. Execution of the KEYBOARD command clears the typeahead buffer. This command is useful for automatically stuffing the keyboard if more key presses are needed than entered. Used in conjunction with the MENU() function or the SET KEY command, multiple selections can be automatically entered by pressing one key. For user defined keyboard macros, see the REPLAY and SET CAPTURE commands.

CLEAR

If the CLEAR keyword is used without a character expression, the keyboard buffer will be emptied. If the CLEAR keyword is used with a character expression, it is processed for Xbase language compatibility.

When PCKEYS is ON, the keys specified with the KEYBOARD command are automatically converted to their logical counterparts according to the current terminal definition.


Example

keyboard chr(ctrl('g'))+chr(ctrl('g'))+'e'


Products

Recital