I would like a script able to capture the screen when a warning window open or an error window
Is it possible ?
Best Regards

Is it possible ?
Best Regards



Well, if you know the title,class or ID of the warning window it might be possible. I can look into making an app that will sit in the system tray and look for specific IDs,Classes and Window titles and then when it see's that window take a screen shot of it. Did you want the whole full screen window or just the window with the error/warning?Only all the windows. And work reverse. Able to see the title, class or ID of the window. so we can select if logs those windows.

Most dialogs will have class #32770. That's probably the impetus for Sikuli. The inability to get info the conventional way. In fact it works by you supplying a capture of the image to recognize.I think you are talking about OCR possibilities. Image Recognition.

You might be able to use Sikuli if you can get it to recognize the warning and/or error icons in dialog boxes.

Hmm, maybe. In order to do something like that, the windows would have to currently be active to take a screen shot and not have another window covering it. So the app would have to cycle through all of the open windows and activate them one at a time to take a screenshot. The window would also have to remain open and active for at least 2-3 seconds.

I think you would have a better idea if you read through the Hello World example for Sikuli:But Miles. Now i am reading javascript : An eye on events.
http://doc.sikuli.org/tutorials/helloworld/helloworld-win.html
As you can see Click() is told what to click by a small image capture. In this example it is the Windows Start Button. But if you can get screen shots of the error dialogs, say the stop sign or yellow triangle for warnings would it not work for those? The whole idea is to use it when conventional window identification fails or is very difficult.



Well, if you know the title,class or ID of the warning window it might be possible. I can look into making an app that will sit in the system tray and look for specific IDs,Classes and Window titles and then when it see's that window take a screen shot of it. Did you want the whole full screen window or just the window with the error/warning?How do you do ?


Original address: https://www.donationcoder.com/forum/index.php?topic=37058.0