XenoGuard 4.0 Documentation

Key Down

ActionStep Reference » Windows » Keyboard » Key Down 

The Keyboard Key Down ActionStep is designed to simulate the pressing of a key on a keyboard. When this ActionStep is triggered, it replicates the initial phase of a keystroke — specifically, the moment a key is pressed down, but not yet released. This ActionStep is particularly useful in scenarios where sustained key presses are required, such as in automated keyboard interactions where a key needs to be held down for a certain duration. It can be used in combination with a corresponding Key Up ActionStep to complete the full keystroke cycle. The Key Down ActionStep is essential for creating more complex, realistic keyboard automation sequences that closely mimic human input.


[-] Hide
  1. Open the Windows node in the Workspace Explorer.
  2. In the Keyboard node, select the Key Down ActionStep.

Parameters:

The ActionStep has the following input parameters:


name Description
Key
Specifies the key to be pressed down.

Allowed Context Scopes [Fixed, Local, Global]
Allowed Context Types [Variable, Parameter, Enum]
Wait Time [ms]
Specifies the time interval in milliseconds after pressing the key down.

Allowed Context Scopes [Fixed, Local, Global]
Allowed Context Types [Variable, Parameter, Enum]

Example 1 (Access the Calculator in the search box):

This example stores the image of the Calculator and the Windows button in two local variables, CalcAppIcon and WindowsButton, respectivelyBoth have Image as their data type. The Windows button is then clicked after it has been detected on the screen and keystrokes the letter "C" to search for the Calculator application. Once the Calculator icon is located on the screen, it is selected by the mouse cursor and opened using the "Enter" keystroke.


See other Keyboard operations:

Write Character
Write Text
Key Press
Key Up