CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
Search Posts SEARCH
Who's Online WHO'S
Log in LOG

Home: Perl Programming Help: Intermediate:
Win32::IEAutomation->new( visible => 0); Taking Focus?



Dec 14, 2011, 4:33 AM

Post #1 of 1 (2649 views)
Win32::IEAutomation->new( visible => 0); Taking Focus? Can't Post


I've written a perl script that uses Win32::IEAutomation->new( visible => 0); To load a few pages that have javascript and frequent dialogue boxes. Which I couldnt get to work with WWW::Mechanize which I normally use.

The script is working perfectly however when the script comes to use load the page the invisible window is taking focus rather than running in the background. Which means like just now my current window loses focus and I was typing nowhere which I'm sure you can imagine is pretty annoying. Also the dialog boxes I'm clicking on using

my $clicker = Win32::IEAutomation::WinClicker->new();
$clicker->push_confirm_button_ok("Message from webpage",2);

are also visible. I've searched online and read the Win32::IEAutomation documentation but cant find anything.

Has anyone encountered this before and found a way round it?

Maybe something not in perl and a system/reg tweak to stop Internet Explorer taking focus?

I'm using Activestate Perl v5.14.4, Windows 7 and Internet Explorer 8.

Any help would be much appreciated!

Many Thanks.



Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives