Tulos Posted September 27, 2008 Share Posted September 27, 2008 Would or should this work? ////////// WinWait("Program Name","") If Not WinActive("Program Name","") Then WinActivate("Program Name","") WinWaitActive("Program Name","") Sleep (5000) If Not WinActive("Program Name","") Then Exit ///////// I ask because sometimes the program the script is to run in closes but the script continues to run and thus creates a mess on my desktop lol Thanks Huserx Link to comment Share on other sites More sharing options...
ssubirias3 Posted September 27, 2008 Share Posted September 27, 2008 . . . sometimes the program the script is to run in closes but the script continues to run and thus creates a mess on my desktop . . .Try something like the below example. Also search the Help file for WinWait() and WinExists() for more information. WinWait("Program Name", "", 3) If WinExists("Program Name", "") Then If Not WinActive("Program Name", "") Then WinActivate("Program Name", "") WinWaitActive("Program Name", "") Sleep(5000) Else Exit EndIf SkysLastChance 1 Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now