Sign in to follow this  
Followers 0
zhaicheng

Using regular expression to match a window?

3 posts in this topic

Is it possible to use regular expression to match a window ’s text ,not a title or classname?

Although I can solve the problem by first getting the text by using "WinGetText" Function, and then matching with "StringRegExp".

Is there any direct way?

Many thanks!

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Is it possible to use regular expression to match a window ’s text ,not a title or classname?

Although I can solve the problem by first getting the text by using "WinGetText" Function, and then matching with "StringRegExp".

Is there any direct way?

Many thanks!

is a PsaltyDS alternative...

Edited by wakillon

AutoIt 3.3.14.2 X86 - SciTE 3.6.0WIN 8.1 X64 - Other Example Scripts

Share this post


Link to post
Share on other sites

That is built into Autoit with "WinTitleMatchMode" Mode 4

WinWait('[REGEXPTITLE:(?i)Windows Media]')  ;RE for Windows Media anywhere in title case insensitive

WinWait('[REGEXPTITLE:xplorer²; REGEXPCLASS:ATL:ExplorerFrame]')   ;RE for xplorer² anywhere in title & Class ATL:ExplorerFrame
It comes in handy when matching Titles or Classes with a colon ":" in them

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