Jump to content
Sign in to follow this  
Drew

ControlGetFocus

Recommended Posts

Drew

Omg , I had this working earlier and I don't know when or why , but I removed it from my code.

All I'm trying to do is get it setup to where $class ( my variable ) will produce the ClassNameNN of whatever window in active at the time.

I could have sworn this is what I was using earlier to test this:

$Class = ControlGetFocus("[active]")

But for whatever reason when I use something such as a MsgBox to ensure that its reading the class , it's not working.

I KNOW I had this working earlier....

Could someone tell me where I'm wrong in that little code , or show me a different way of getting the ControlRef# for me to use in a ControlClick?

Please and Thank you very much ,

*Drew

Share this post


Link to post
Share on other sites
Andreik

Omg , I had this working earlier and I don't know when or why , but I removed it from my code.

All I'm trying to do is get it setup to where $class ( my variable ) will produce the ClassNameNN of whatever window in active at the time.

I could have sworn this is what I was using earlier to test this:

$Class = ControlGetFocus("[active]")

But for whatever reason when I use something such as a MsgBox to ensure that its reading the class , it's not working.

I KNOW I had this working earlier....

Could someone tell me where I'm wrong in that little code , or show me a different way of getting the ControlRef# for me to use in a ControlClick?

Please and Thank you very much ,

*Drew

Look here maybe helps you.

When the words fail... music speaks

Share this post


Link to post
Share on other sites
rasim

Drew

You forgot switch to advanced mode

Opt("WinTitleMatchMode", 4)

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  

×