Monday, May 11, 2009

Using Win32::GuiTest to send a keystroke

Sending keystrokes with Win32::GuiTest is straightforward. Really straightforward.

One key:
SendKeys('{ENTER}');

Multiple keys:
my @keys = ( "%{F}", "{RIGHT}", "E", );
my $pause_between_keypress = 1;
for my $key (@keys) {
SendKeys( $key, $pause_between_keypress );
}

No comments:

Labels

Blog Archive

Contributors