keyboard.sendkeys(keys)function

Sends virtual key presses to other applications.

Parameters

keys

A string that contains one or more key codes/commands combination.

Return value

This function true if the key/command sequence has been successfully sended, or false otherwise.

Example

--! luart-extensions import keyboard -- Send virtual keys to launch the Windows Run... command -- then types "notepad", presses Enter, and enters slowly the letters Hello LuaRT ! print(keyboard.sendkeys("{DELAY=100}@rnotepad{ENTER}{DELAY=600}H{DELAY=100}ello LuaRT !"))