Jump to content

adjusting mouse coordinates for different screen sizes


Recommended Posts

My program involves many mouse clicks, which I designed for use on my computer. If I wanted to run it on a different machine, is there a way to either adjust the screen size on that machine to match mine or to automatically alter the coordinates in the code so that they all end up clicking on the correct spot?

Link to comment
Share on other sites

use autoit window info utility when writing your script. set option/coord mode to "window". note the x,y coordinates while writing your script under the window info utility "mouse" tab. these coordinates will stay constant reguardless of window position or screen resolution. add this to the top of your script:

Opt("MouseCoordMode",0)

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...