in reply to Re: GUI Automation - locate image
in thread GUI Automation - locate image

Thanks, but Application is running within a windows frame utilizing some Java SunAwtCanvas... anything within it is not visible to me from Perl. only graphically. Found the Win32::ActAcc module, here is the Perl code I used to detect any "lasting change" over a 2 second period... It appears very handy for working with other applications...
use Strict; use Win32::OLE; use Win32::ActAcc; use Win32::GuiTest qw(:ALL :SW); my @win; my %Wnm; my %VW; Win32::OLE->Initialize(); while ( 1 ) { @win = (); @win = FindWindowLike(); #*# report any "lost" windows: for $win ( @win ) { delete $Wnm{$win}; } if ( scalar keys %Wnm) { print "Lost:\n"; my @Lost = sort keys %Wnm; for (@Lost) { print "$Wnm{$_}\n"; delete $Wnm{$_}; } print "\n"; } for $win ( @win ) { dumpwin($win); } print "\n----\n"; sleep(2); } exit; sub dumpwin { my $win = shift; print "Null handle\n", return unless ($win); my $w_text = $win . ' ' . GetWindowText($win); $w_text .= " class=" . GetClassName($win); my $w_state = ' V=' . IsWindowVisible($win) . ' E='; $w_state .= IsWindowEnabled($win); $Wnm{$win} = $w_text . ' ' . $w_state; my $ao = Win32::ActAcc::AccessibleObjectFromWindow($win); my $aatxt = ''; $aatxt = $ao->describe() if defined $ao; $w_state .= ' ' . $aatxt; if ( exists $VW{$win} ) { return if ( $VW{$win} eq $w_state ); } $VW{$win} = $w_state; print $win, GetWindowText($win); print " class=", GetClassName($win); print " vis=", IsWindowVisible($win); print " en=", IsWindowEnabled($win); print "\n ",$aatxt, "\n"; }