tlokz Posted August 25, 2008 Posted August 25, 2008 (edited) Made a tool that will get x/y coordinates for MouseClick... will automatically add Opt("MouseCoordMode", 2)WinTitle()WinWaitActive()Will add those again if win title changesF1 grabs coordinates and F2 clears clipboardIts all saved in clip boardSample Output:Opt("MouseCoordMode", 2)WinActivate("AutoIt Forums -> Posting New Topic - Mozilla Firefox")WinWaitActive("AutoIt Forums -> Posting New Topic - Mozilla Firefox")MouseClick("left", 121, 103)WinActivate("Awesom-O • User Control Panel • Compose message - Mozilla Firefox")WinWaitActive("Awesom-O • User Control Panel • Compose message - Mozilla Firefox")MouseClick("left", 132, 73)WinActivate("Getting Started with Firefox - Mozilla Firefox")WinWaitActive("Getting Started with Firefox - Mozilla Firefox")MouseClick("left", 228, 74)Source:Opt("MouseCoordMode", 2) $win2 = "" ClipPut('Opt("MouseCoordMode", 2)') HotKeySet("{F1}", "_GetPos") HotKeySet("{F2}", "_ClearClip") While 1 Sleep(500) WEnd Func _GetPos() $anothertemp = @CRLF $mousepos = MouseGetPos() $win = WinGetTitle("") If $win <> $win2 Then $anothertemp &= 'WinActivate("' & $win & '")' & @CRLF & 'WinWait("' & $win & '")' & @CRLF $anothertemp &= 'MouseClick("left", ' & $mousepos[0] & ", " & $mousepos[1] & ")" ClipPut(ClipGet() & $anothertemp) $win2 = $win EndFunc Func _ClearClip() ClipPut('Opt("MouseCoordMode", 2)') $win2 = "" EndFunc Edited August 25, 2008 by tlokz
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