LLPlayer.KeyUp Method

Applies to TestComplete 15.70, last modified on December 17, 2024

Description

Use the KeyUp method to simulate the release of a key specified by its virtual-key code. The method performs the same action as the KeyUp event of a low-level procedure.

Declaration

LLPlayer.KeyUp(VKCode, Delay)

VKCode [in]    Required    Integer    
Delay [in]    Required    Integer    
Result None

Applies To

The method is applied to the following object:

Parameters

The method has the following parameters:

VKCode

The code of the key to release. For a list of key codes, see the Virtual-Key Codes article in the MSDN library.

If the Win32API plugin is installed and enabled in TestComplete, you can use the named constants VK_xxxx instead of the hard-coded key code values. The available VK_xxxx constants are listed under the Win32API node in the Code Completion window.

Delay

The number of milliseconds passed after you command TestComplete to simulate the release of a key and before TestComplete starts simulating the release. The delay gives you the possibility to better emulate real-life conditions. Also, it is necessary so the key press can be properly processed by the operating system.

If Delay is negative, it is set to the Auto-wait timeout.

If Delay is greater than 1000, the waiting progress will be shown in the TestComplete indicator during the test run.

Result Value

None.

Example

To view an example that demonstrates how to use the KeyUp method, see the KeyDown help topic.

See Also

Testing Applications in Low-Level Mode
KeyDown Method
Low-Level Procedure Events
KeyUp Method (Desktop Objects)
Keys Action
Keys Method
Simulating Keystrokes

Highlight search results