Sign in to follow this  
Followers 0
Jaccus

WinActivate() problem

5 posts in this topic

My problem:

Using function WinActivate() for 2 similar windows titles (with window titles like: "window1" and "window10")

sometimes activates wrong one.

The problem is that the following text is the same (in first 7 letters) and WinActivate() function doesn't use sth like 'case sensitive match' for windows selection.

My questions:

How to use only 'case sensitive match' for window selection? (if it's possible)

If it's not possible, how to solve my problem?

Thanks.


Share this post


Link to post
Share on other sites



You can use the "text" parameter of any Win* call to narrow the search to a specific window. You can use WinActivate("window1", "unique text") to activate a window with only the unique text.


Who else would I be?

Share this post


Link to post
Share on other sites

You can use the "text" parameter of any Win* call to narrow the search to a specific window. You can use WinActivate("window1", "unique text") to activate a window with only the unique text.

What if my windows are plain inside? Only 'Title Bar' is available to use with WinActivate().

Any more solutions?


Share this post


Link to post
Share on other sites

What if my windows are plain inside? Only 'Title Bar' is available to use with WinActivate().

Any more solutions?

Have you used AutoIt Window Info tool on the windows to see if it shows any differences.


Get Beta versions Here Get latest SciTE editor Here AutoIt 1-2-3 by Valuater - A great starting point.

Time you enjoyed wasting is not wasted time ......T.S. Elliot
Suspense is worse than disappointment................Robert Burns
God help the man who won't help himself, because no-one else will...........My Grandmother

Share this post


Link to post
Share on other sites

What if my windows are plain inside? Only 'Title Bar' is available to use with WinActivate().

Any more solutions?

look up WinTitleMatchMode option in help file. it's an option that you can set with Opt() to configure the matching behavior of functions that use window titles.

1100111 00001011101111 00011101101111 00010111100100 00001111110100 00110111110010 00101101111001 0011100i didn't make up this form of encryption, but i like it.credit to the lvl 6 challenge on arcanum.co.nz

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