Go on script even if there is unexpected windows ?

Hints, tips and tricks for newbies

Moderators: Dorian (MJT support), JRL

Post Reply
ElisaH
Newbie
Posts: 1
Joined: Tue Jun 19, 2012 3:27 pm
Location: France

Go on script even if there is unexpected windows ?

Post by ElisaH » Tue Jun 19, 2012 3:38 pm

Hello, Bonjour !

I'm new beginer (so excuse my questions and my English Language...).

I made my first script. It works good. BUT, as I need to use the Image Search in Windows... if there is inconvenient windows like "Hello, new version of Windows", or any windows... the script doesn't find (of course) the image I want... and then... never ends.... and doesn"t do what it has to.


Do you have solutions in order the script is good, AND look at ANY windows for looking for ScreenCapture and FindImagePos?
FindImagePos doesn't operate if there is a new inexcepted windows opened. What can I do to ask MacroScheduler to look in ALL windows, OR, to stay in the same one ?

I hope to be "understandabled"...

Best regards


Elisabeth
Beginner...

User avatar
Marcus Tettmar
Site Admin
Posts: 7395
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Post by Marcus Tettmar » Tue Jun 19, 2012 4:40 pm

Have a look at this:
http://www.mjtnet.com/blog/2008/03/04/o ... e-dialogs/

There are limits of course. You will have to make some assumptions as to how to clear these windows as not all will be the same and you can't guarantee every possible window will work the same way. But you can at least log unexpected windows.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts