Jump to content

Recommended Posts

Posted

hey... i need the current control that is under the mouse. for some reason this doesn't work so i'm not sure how to do this.

#include <GUIConstants.au3>

...

Func enable()
    $a = GUIGetCursorInfo()
    If IsArray($a) Then ControlEnable("","",$a[4])
    MsgBox(0,"",$a[4])
EndFunc
Posted

okay... i might of found out why... "GUIGetCursorInfo()" i think is only meant to work on the gui that is created by a script its running in... how does the autoit window info get its control id's? Thats more of what i'm looking for... for it to work with any window.

Posted

"GUIGetCursorInfo()" i think is only meant to work on the gui that is created by a script its running in

That's right. Use _ControlGetHandleByPos() in conjunction with MouseGetPos().

[font="Tahoma"]"Tougher than the toughies and smarter than the smarties"[/font]

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
  • Recently Browsing   0 members

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