Jump to content

WinWait Don't wait for shhh ?


Recommended Posts

Every time I use

Opt("WinTitleMatchMode", 4) with winwait seems like it always hangs on WinWait because I can't use wintitlematchmode 3 ,2 1 because it has to be exactley what I'm looking for or it will not work..

Link to comment
Share on other sites

Every time I use

Opt("WinTitleMatchMode", 4) with winwait seems like it always hangs on WinWait because I can't use wintitlematchmode 3 ,2 1 because it has to be exactley what I'm looking for or it will not work..

You're probably using it wrong. Post a short demo script that shows your issue, and we can figure it out.

:rolleyes:

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Link to comment
Share on other sites

directly from the help file

Mode 4

Advanced mode.

In this mode special sequences are used in the title parameter so that window classnames and handles can be used. The text parameter remains the same.

The special sequences must contain no whitespace. They are:

"classname=CLASSNAME"

"regexp=REGEXP"

"active"

"last" or ""

"classname=" matches a window based on its classname. For example to identify a window that has the classname "MYCLASS1" then you would use "classname=MYCLASS1" for the title parameter.

"regexp=" matches a window matching REGEXP pattern.

"active" matches the currently active window (same as "" in the default WinTitleMatchMode).

"last" uses the last successful window match so you don't have to keep specifying the title and text again and again. e.g.

AutoItSetOption("WinTitleMatchMode", 4)
WinWaitActive("Untitled - Notepad")
WinClose("last")    ; Closes the previously matched notepad window

Note: If "classname=", "regexp=", "active", "last" or "" are not used as the title then the window matching takes place as in Mode 1 making this a good mode for general use.

Link to comment
Share on other sites

that isnt demo...

i dont see whats wrong heare,

winwaitactive is waiting that any window with that title become active, and on activation (mouse click or WinActivate) he close it,

on the first post you whas writing command winwait, so r y waiting the window to exists so that you can close it when he popup, or y r waiting to activate (set focus) on the window with that name so that script can close it?

can you write, what r you trying or what do you need from script todo with notepad window in what moment... and what is happening (what do you think is wrong)

Link to comment
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
 Share

  • Recently Browsing   0 members

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