Difference between revisions of "ISInterface:EmulateKeyPress"
Jump to navigation
Jump to search
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
===Syntax=== | ===Syntax=== | ||
− | + | *bool EmulateKeyPress(char *Combo, bool Hold) | |
== Purpose == | == Purpose == | ||
− | + | To emulate a keyboard key press | |
== Usage == | == Usage == | ||
=== Parameters === | === Parameters === | ||
− | + | *char *Combo | |
+ | :'''[in]''' Key combo to be pressed | ||
+ | *bool Hold | ||
+ | :'''[in]''' if TRUE the keys will be held, if not they will be pressed and released | ||
=== Return Value === | === Return Value === | ||
− | + | *bool | |
+ | :Returns true on success, false on failure | ||
== Examples == | == Examples == | ||
− | + | ===Press a key and release it=== | |
+ | *pISInterface->EmulateKeyPress("ctrl+7",FALSE); | ||
+ | ===Press a key and hold it=== | ||
+ | *pISInterface->EmulateKeyPress("shift",TRUE); | ||
== See Also == | == See Also == | ||
* [[ISXDK:ISInterface|ISInterface]] | * [[ISXDK:ISInterface|ISInterface]] | ||
+ | * [[ISInterface:EmulateTyping|EmulateTyping]] | ||
+ | * [[ISInterface:EmulateKeyRelease|EmulateKeyRelease]] | ||
[[Category:ISXDK]] | [[Category:ISXDK]] | ||
[[Category:ISInterface]] | [[Category:ISInterface]] |
Latest revision as of 23:25, 2 September 2005
Contents
Syntax
- bool EmulateKeyPress(char *Combo, bool Hold)
Purpose
To emulate a keyboard key press
Usage
Parameters
- char *Combo
- [in] Key combo to be pressed
- bool Hold
- [in] if TRUE the keys will be held, if not they will be pressed and released
Return Value
- bool
- Returns true on success, false on failure
Examples
Press a key and release it
- pISInterface->EmulateKeyPress("ctrl+7",FALSE);
Press a key and hold it
- pISInterface->EmulateKeyPress("shift",TRUE);