Cumberland Mike Posted May 18, 2005 Share Posted May 18, 2005 Is there a way to have AutoIt wait for a mouse click then it would proceed to close the open window and ... move on through the rest of the script. I can not find out how to have it recognize a mouse click ... the pointer is not imprtant ... nor is its position ... just need to recognize the click ... and move on Any help is greatly appreciated TIA Mike Link to comment Share on other sites More sharing options...
buzz44 Posted May 18, 2005 Share Posted May 18, 2005 (edited) While 1 $msg = GUIGetCursorInfo () If $msg[2] = 1 Then MsgBox(4096,"Test","You pressed the primary button.") ElseIf $msg[2] = 1 And $msg[3] = 1 Then MsgBox(4096,"Test","You pressed the primary and secondary buttons.") ElseIf $msg[2] = 1 Or $msg[3] = 1 Then MsgBox(4096,"Test","You pressed the primary or secondary buttons.") EndIf WendOr you can use GUIGetMsg()While 1 $msg = GUIGetMsg() If $msg = $GUI_EVENT_PRIMARYDOWN Then MsgBox(4096,"Test","You pressed the primary button.") ElseIf $msg = $GUI_EVENT_PRIMARYDOWN And $msg = $GUI_EVENT_SECONDARYDOWN Then MsgBox(4096,"Test","You pressed the primary and secondary buttons.") ElseIf $msg = $GUI_EVENT_PRIMARYDOWN Or $msg = $GUI_EVENT_SECONDARYDOWN Then MsgBox(4096,"Test","You pressed the primary or secondary buttons.") EndIf WendGUIGetMsg() has more options such as.$GUI_EVENT_PRIMARYDOWN$GUI_EVENT_PRIMARYUP$GUI_EVENT_SECONDARYDOWN$GUI_EVENT_SECONDARYUP Edited May 18, 2005 by Burrup qq 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