Sign in to follow this  
Followers 0
NewtonScripter

Wait for program to finish loading

7 posts in this topic

Hello

I am a little new to autoit.

How do you wait for a program to finish loading?

I want to start a program

wait for it to load

then send "!f" then "i" to import files.

My only issue iw waiting for the program to finish loading

Thanks

Share this post


Link to post
Share on other sites



Run("YourProgram.exe");Run teh shiet

WinWaitActive("TheCaptionOfTheProgram");Or something like that...

Send("!f")
Send("i")

While(1)

;INFINITE LOOP FTW D:

WEnd

Like... That? :3

Share this post


Link to post
Share on other sites

Yea I tried winwaitactive.

Like the window starts, but then there is a splash screen that shows it is loading.

I'm guessing it's because it's loading when it does the alt+f, i thing.

I don't want to make it wait for a fix time, but if there is no other solution I guess i will have to.

Share this post


Link to post
Share on other sites

What program is it?

Share this post


Link to post
Share on other sites

Get the text inside (not the title bar) of the window.

Then:

Run("Your Program.exe")

WinWaitActive("ProgramTitle", "WindowText")
Send("!f")
Send("i")

[center]It's a question of mind over matter, if I don't mind, it doesn't matter.[/center]

Share this post


Link to post
Share on other sites

Yea I tried winwaitactive.

Like the window starts, but then there is a splash screen that shows it is loading.

I'm guessing it's because it's loading when it does the alt+f, i thing.

I don't want to make it wait for a fix time, but if there is no other solution I guess i will have to.

try to use Advanced Window Descriptions.

WinWaitActive("[TITLE:My Window; CLASS:My Class; INSTANCE:2]", "")

You should use AU3Info for getting class name of your window.

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  
Followers 0