RanorexRanorex Documentation
Press Method (key, scanCode, keyPressTime, times, setModifiers)
NamespacesRanorexKeyboardPress(Keys, Int32, Duration, Int32, Boolean)
Presses and releases the specified key for the specified number of times.
Declaration Syntax
C#Visual BasicVisual C++
public static void Press(
	Keys key,
	int scanCode,
	Duration keyPressTime,
	int times,
	bool setModifiers
)
Public Shared Sub Press ( _
	key As Keys, _
	scanCode As Integer, _
	keyPressTime As Duration, _
	times As Integer, _
	setModifiers As Boolean _
)
public:
static void Press(
	Keys key, 
	int scanCode, 
	Duration^ keyPressTime, 
	int times, 
	bool setModifiers
)
Parameters
key (Keys)
The key.
scanCode (Int32)
The hardware scan code for the key. Specify DefaultScanCode to use the default scan code for the specified virtual key.
keyPressTime (Duration)
The time between pressing and releasing the key.
times (Int32)
The number of times to press the key.
setModifiers (Boolean)
A value specifying whether to set the modifiers specified in the key.

Assembly: Ranorex.Core (Module: Ranorex.Core) Version: 3.2.3.16825 (3.2.3.16825)