shayak has asked for the wisdom of the Perl Monks concerning the following question:
#! usr/bin/perl #use Win32::Gui; use Win32::GuiTest qw(:ALL); use strict; my $window = FindWindowLike( undef,"[Install*.*|*Setup.*]","" ); while(1) { for($window) { SetForegroundWindow($window); my @hwnds = GetChildWindows($window); foreach(@hwnds) { SetForegroundWindow($_); my $var = GetWindowText($_); print "shayak"; print $var; my $class = GetClassName($_); print $class; #my $child = GetChildDepth(GetDesktopWindow(), $_); #print $child; if ($class == ["*RadioButton"]) { my $id=GetWindowID($_); print $id; #CheckButton(GetWindowID($name); if (WMGetText($id)==(["*agree*" ]or ["*accept*"])) { CheckButton($id); } else { SendKeys{"TAB"}; SendKeys{"UP"}; } } #PushButton("Next" or "Agree" or "Install" or "Yes" or "Fi +nish" or "Done"); SendKeys("~"); } } }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Gui Automation using guitest
by Anonymous Monk on Feb 15, 2011 at 07:55 UTC | |
| |
|
Re: Gui Automation using guitest
by Anonymous Monk on Feb 15, 2011 at 07:20 UTC | |
by shayak (Acolyte) on Feb 15, 2011 at 07:24 UTC | |
by Anonymous Monk on Feb 15, 2011 at 07:28 UTC | |
by shayak (Acolyte) on Feb 15, 2011 at 07:33 UTC | |
by shayak (Acolyte) on Feb 15, 2011 at 07:35 UTC | |
| |
|
Re: Gui Automation using guitest
by Sinistral (Monsignor) on Feb 16, 2011 at 13:31 UTC | |
by shayak (Acolyte) on Feb 17, 2011 at 12:32 UTC |