Jump to content
Sign in to follow this  
nickwhite

Scripts not working good on slower machines

Recommended Posts

nickwhite

I use AutoIt for automating tasks like file associations, running a program and clicking some checkboxes and buttons. For this I frequently use:

WinWaitActive("title")
Send("keys") OR ControlClick("title", "text", "control")

All the scripts run fine on modern machines. But recently, I used the scripts on a slower machine, a PIII @ 1 GHz with 224 MB RAM & WinXP. Some scripts worked (on applications that launch fast), but others got "stuck" at some points.

For example, after launching an application, I used the Send() function and then wait for the options window to appear and get focus and then it was going to do some control clicks. The application launched, but no options window opened. I opened it manually, then the script continued its job.

Can this be fixed in some way? Does the WinWaitActive() function wait for the whole window to load (with all of its controls)?

Share this post


Link to post
Share on other sites
Richard Robertson

WinWaitActive waits until a window that matches the specifications you provide to become the active window. Being active has nothing to do with the state of the window. I believe it will even return if a window is locked up, as long as it is the active window.

Share this post


Link to post
Share on other sites
LarryDalooza

Error / Success ... you have to code it...

While (My window is not here)

ControlClick(My Button)

Sleep(a little bit)

WEnd


f_mrcleansmalm_77ce002.jpgAutoIt has helped make me wealthy

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×