Sign in to follow this  
Followers 0
charvi

Clickable Screen Zone?

3 posts in this topic

I was wondering if there is a way to click anywhere on the screen, and depending of the location it was clicked, I would like to:

1) get the X,Y pixel location in variables $x and $y

2) know what it returns to the event $Msg

This because I have placed fake buttons on the screen - that are just pictures - but that they act if they were real buttons.

I hope that someone has a nice script example...

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

for #1 try

#include <misc.au3>
while 1 
   $mouse = mousegetpos()
   $x = $mouse[0]
   $y = $mouse[1]
   if _ispressed(01) then 
      msgbox(0,"",$x&"-"&$y)
   endif
wend

#2 try using the advanced mode in guigetmsg. $msg = guigetmsg(1)

Edited by Rental

Share this post


Link to post
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
Sign in to follow this  
Followers 0