Sign in to follow this  
Followers 0
eKolin

Detect GUI (simple question)

6 posts in this topic

So, basicly i want to detect GUI AND use it's coordinates only. I hope that my image will explain it good enough.

J3ExNE3.jpg

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

@eKolin I am guessing you are looking to use Mouse functions. Look at MouseCoordMode in the help file to set it relative to the active window.

Or, you can give a better explanation of what you're trying to accomplish and we can help you get away from all the messy Mouse-work altogether ;)

Edited by JLogan3o13
1 person likes this

When you're dead, you don't know you're dead - it's only difficult for those that know you. It's the same way when you're stupid...

My Scripts: SCCM UDFInclude Source with Compiled Script, Windows Firewall UDF

Share this post


Link to post
Share on other sites

@JLogan3o13 My goal is to use the interface coordinates instead of whole monitor coordinates = I can move the GUI without a worry that the coordinates will be incorrect. Thanks in advance ;)

Share this post


Link to post
Share on other sites

I understand your goal; my question is why must you use Mouse functions on the GUI (is this a GUI you've created?). If you get the ID of the control you want to interact with, and use the Control* commands, it won't matter where the GUI is moved to :)


When you're dead, you don't know you're dead - it's only difficult for those that know you. It's the same way when you're stupid...

My Scripts: SCCM UDFInclude Source with Compiled Script, Windows Firewall UDF

Share this post


Link to post
Share on other sites

@JLogan3o13 My bad, i wasn't familiar with this function, basicly what i wanted was:

Opt(MouseCoordMode,0)

I don't really understand the difference between parameters 0 and 2 (probbably because i lack english skills) Can you explain please?

0 = relative coords to the active window
1 = (default) absolute screen coordinates
2 = relative coords to the client area of the active window

 

Share this post


Link to post
Share on other sites

@eKolin as I tell my son who is just beginning his journey into scripting - sometimes it is better to do it yourself than to have someone tell you. Mock up a script and try out the difference between 0 and 2; it should become pretty apparent to you. :)

1 person likes this

When you're dead, you don't know you're dead - it's only difficult for those that know you. It's the same way when you're stupid...

My Scripts: SCCM UDFInclude Source with Compiled Script, Windows Firewall UDF

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