Mellon Posted October 3, 2009 Posted October 3, 2009 After a search and checking the doc I am pretty sure the answer is NO but I thought I would check. Do ..... ..... In this event A=8 In some other event B=2 Until A=8 or B=2 Is it possible to use an "or" in an Do...Until loop as I did above?
monoceres Posted October 3, 2009 Posted October 3, 2009 Why didn't you try first? Your code is valid syntax. Broken link? PM me and I'll send you the file!
Mellon Posted October 6, 2009 Author Posted October 6, 2009 Oh, I did try it. It didn't work as it was written so I assumed it wasn't valid. I look into the code it is supposed to work with.
jebus495 Posted October 6, 2009 Posted October 6, 2009 Oh, I did try it. It didn't work as it was written so I assumed it wasn't valid. I look into the code it is supposed to work with. The answer is yes. HotKeySet("{INSERT}", "TEST") While 1 Sleep(50) ToolTip("Press ""Insert"" to test.", @DesktopWidth/2 -100, @DesktopHeight/2 -100) WEnd Func TEST() Do $A = Random(1, 10, 1) $B = Random(1, 10, 1) Until $A = 8 Or $B = 2 Select Case $A = 8 MsgBox(0, "Hello", "It was A") Case $B = 2 MsgBox(0, "Hello", "It was B") EndSelect EndFunc
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