Cicode Programming Reference > Cicode Function Categories > Keyboard Functions Introduction > KeyPut

KeyPut

Puts an ASCII key code or Keyboard key code into the last position of the key command line. If this key completes any command, that command will execute.

Syntax

KeyPut(KeyCode)

KeyCode:

The key code to put into the key command line.

Return Value

0 (zero) if successful, otherwise an error is returned.

Related Functions

KeyGet

Example

KeyPut(Key_F1);
/* Puts "Key_F1" (the Key Code for the "F1" key) into the last position of the key command line. If "START" is the Key Name for the "F1" key, this would be equivalent to
KeyPutStr("START"). In either case, "START" will display on the key command line. */
KeyPut(StrToChar("A"));
/* Puts the Key Code for the "A" key into the last position of the key command line. */

See Also

Keyboard Functions