Jump to content

Request mouse position...


Recommended Posts

Hi everyone, it has been a few years since I have played with autoIT and I wanted to start with a simple script that will make a dialog box asking you to click in a certain area (in a different window) and upon click, it will record the location to a variable and then close the dialog box. I can't find a good tutorial on how to do this, however, so I thought it was worth a shot to ask for some help! Thanks in advance.

Link to comment
Share on other sites

  • Developers

You mean you actually looked for information in the Helpfile and Forum to see if there was information available?

Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

find mouse click, find mouse location, get mouse location, mouse location, get mouse position onclick. Things like that. Most everything pointed me towards the autoit spy (autoitinfo.exe) which is great, but does not accomplish what I need done. If I missed something obvious someone please point it out.

Link to comment
Share on other sites

If you don't want to use hook. You can let the user press your GUI and without releasing the mouse button move the cursor to the tree and release the mouse button there. This way you'll receive a $WM_LBUTTONUP message, then use MouseGetPos or something. This approach is like the Finder Tool of AutoIt Window Info tool. Another way would be to use a hot-key. If you're insisting to perform it via a mouse click, I guess that your easy solution would be to use mouse hook.

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...