keilamym Posted April 13, 2004 Posted April 13, 2004 is there an easy way to loop in a script, based on a window or variable? example - if a window or file doesn't appear, i want the script to loop a process (not using winwait) example. look for c:\complete.txt if it does not exist, sleep for 5 seconds then look again. if it finds it, then continue processing the script, if it does not, look again. In version2, i would use goto commands with error levels, but goto doesn't exist in 3? any help would be appreciated. keilamym
Developers Jos Posted April 13, 2004 Developers Posted April 13, 2004 (edited) untested: While not FileExists("c:\complete.txt") Sleep(5000) Wend Edited April 13, 2004 by JdeB SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
scriptkitty Posted April 13, 2004 Posted April 13, 2004 Yea, I use one like this to start up a script on one computer when anouther one updates a file: While NOT FileExists("P:\removes"&@mon&"-"&@Mday&".txt") sleep(1000) Wend P: is a network drive AutoIt3, the MACGYVER Pocket Knife for computers.
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