Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am trying to create a script (pls be aware that I am not a programmer) using AutoHotkey that opens a web site, positions the mouse at a specified clickable icon and click repeatedly in a pre-determined time interval until the mouse is physically moved. I seem to be able to succeed in all the steps except being able to position the cursor/mouse at the correct spot where the "click" should take place.

I used the built-in "Window Spy" facility to find the pixel position where I want the "click" to take place but this x,y value remains the same even when the active window is manually adjusted (I have to scroll up in order to locate the position I want to click since my laptop's screen size cannot handle the active window size). So, how do I locate the mouse position regardless of the screen size of the computer I happen to use?

Thank you!

share|improve this question
It's it necessary that the 'click' be from a mouse button? Can you gain focus of the element with Tab and 'click' using Enter? I don't think AutoHotkey can click a position off screen. – iglvzx Feb 4 '12 at 5:43

You could try using MouseClick to send mouse wheel commands and scroll the location you want to click onto the screen. Then position your mouse where you need it to be and start clicking.


That line will scroll the mouse up through 10 detents (wheel clicks).

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.