IWinApplicationClass.GetKeyState

Syntax

GetKeyState(Key: Keys): Boolean;

Parameters

Key. The key, which state is to be checked.

Description

The GetKeyState method returns status (pressed or released) of a key in the message queue.

Comments

The method returns True if the key passed by the Key parameter is currently pressed.

On executing long-term processes the message queue is processed with application after completing the process. In this case it is recommended to use the GetAsyncKeyState method.

See also:

IWinApplicationClass