jimmer Posted October 29, 2014 Share Posted October 29, 2014 (edited) Is there anyway for me to use MouseClickDrag or MouseWheel through ControlClick or ControlSend? Been trying to test it out but I can't seem to figure out if it's possible or if I will need the physical cursor present for those commands. Edited October 29, 2014 by jimmer Link to comment Share on other sites More sharing options...
dewcansam Posted October 29, 2014 Share Posted October 29, 2014 Actually what it sounds like you are after is as simple as: AutoItSetOption ("MouseCoordMode" ,1) WinWaitActive("My Program") MouseMove(1009, 336) MouseWheel("down", 50) You don't have a sample of your code, so I am not sure what the Title would be for the 'WinWaitActive()' command. Regardless open up AutoIt Window Info. Figure the cords of the control you are trying to interact with and if your users are going to be moving your window around on screen. Then set 'AutoItSetOption("MouseCoordMode" ,0)' or set the param to '2'. Do the MouseMove command then MouseWheel. Without more info, not much else we can do. Link to comment Share on other sites More sharing options...
jimmer Posted October 29, 2014 Author Share Posted October 29, 2014 (edited) This is what I am using for mouse clicks. $handle = WinGetHandle("FireFox", "") ControlClick($handle,"","","",1,x,y) What I am trying to accomplish is for the window to use the mouse wheel while minimized, or would it need the cursor present for the task? Edited October 29, 2014 by jimmer Link to comment Share on other sites More sharing options...
jdelaney Posted October 29, 2014 Share Posted October 29, 2014 (edited) Use the _FF.au3 (firefox) to perform the DOM click on your object. Edited October 29, 2014 by jdelaney IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window. Link to comment Share on other sites More sharing options...
jimmer Posted November 4, 2014 Author Share Posted November 4, 2014 (edited) FireFox was just one of the applications. Is there something that is more universal? I know that ControlClick("","","","BUTTON,clicks,x,y) but BUTTON seems to only be Left Click, Right Click, Middle Click. But it doesn't have WheelUp or WheelDown. I am wondering if there is any sort of MouseWheel that can be sent to a window that isn't focused with the use of the ControlClick or ControlSend? Edit: Upon further reading, I realize it is not possible to MouseClickDrag without changing focus. I am still hopeful that I can use MouseWheel. Is anyone able to verify this is not possible? I need closure. Edited November 5, 2014 by jimmer 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