pijush has asked for the wisdom of the Perl Monks concerning the following question:
I am trying to install a software in Windows. The s/w has only GUI mode installation. I have found that Win32::Setupsup module can be used to automate the installation. But when I was trying to use this module, I faced a problem to send data in a text field and then press the "next" button. I have installed the module in Perl v5.6.1 on w2k. Here is my code
But the keystroke is not going to the text field which is desirable to me. Any pointer how to send keystroke to the text field? Any help really appreciated.use strict; use Win32::Setupsup qw(WaitForAnyWindow GetWindowProperties SendKeys S +etFocus); my ($window); system (1, "setup.exe"); if (WaitForAnyWindow("windows name", \$window, 6000, 500)) { SetFocus ($window); sleep (2); SendKeys ($windows,'textvalue',1); sleep (1); SendKeys ($windows,'\\TAB\\',1); sleep (1); SendKeys ($windows,'\\RET\\',1); sleep (2); }
Thanks in advance.
-Pijush
Edit by tye, preserve formatting
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Help needed for using Win32::Setupsup module
by Albannach (Monsignor) on Nov 21, 2003 at 17:09 UTC | |
by pijush (Scribe) on Nov 21, 2003 at 17:43 UTC | |
by pijush (Scribe) on Nov 21, 2003 at 19:19 UTC |