StandardUser Posted May 30, 2010 Posted May 30, 2010 (edited) More exactly, it works perfectly when waiting just for 1 window, e.g. Opt("WinTitleMatchMode", 2) WinWait("Notepad" ,"",10) But when I try to make it wait for any of 2 windows, it just doesn't work, e.g. Opt("WinTitleMatchMode", 2) WinWait("Notepad" Or "Calculator","",10) I would be really grateful for any hint or workaround. Edited May 30, 2010 by 871
zeffy Posted May 30, 2010 Posted May 30, 2010 (edited) WinWait can't contain And / Or, I would recommend using something like this: Opt("WinTitleMatchMode", 2) While 1 If WinExists("Notepad", "", 1) Then ExitLoop If WinExists("Calculator", "", 1) Then ExitLoop Sleep(50) WEnd Edited May 30, 2010 by Zef
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