How to? Does WAITWIN (in sysutils.dll) detect title change?

  • This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.
#1
WinXP home SP3 (32b) / TCC 14.03.53
2012-11-28@23:05:58 102,912 083F1360 sysutils.dll

Vince:
Can I use WAITWIN to delay my batch file until the title of an existing window (latest Firefox) changes to the desired string? If so, how? The command "waitwin /i /caption %1" seems to just hang until a BREAK signal...
--
Steve
 
#2
WinXP home SP3 (32b) / TCC 14.03.53
2012-11-28@23:05:58 102,912 083F1360 sysutils.dll

Vince:
Can I use WAITWIN to delay my batch file until the title of an existing window (latest Firefox) changes to the desired string? If so, how? The command "waitwin /i /caption %1" seems to just hang until a BREAK signal...
--
Steve
The WinEvent hook used by WAITWIN looks only for EVENT_OBJECT_[CREATE | DESTROY | SHOW | MOVESIZESTART]. So it's not going to detect a change of caption.

There does exist EVENT_OBJECT_NAMECHANGE (said to apply to window objects) but I don't know if that will detect a change of caption. I'll experiment.
 
#3
WinXP home SP3 (32b) / TCC 14.03.53
2012-11-28@23:05:58 102,912 083F1360 sysutils.dll

Vince:
Can I use WAITWIN to delay my batch file until the title of an existing window (latest Firefox) changes to the desired string? If so, how? The command "waitwin /i /caption %1" seems to just hang until a BREAK signal...
--
Steve
Steve, I (rather hastily) added the option "/NC" (new_caption) to WAITWIN. In simple tests it works. I used "WAITWIN /NC /I /CAPTION foo".
I'll try to attach STEVE.ZIP (containing an experimantal sysutils.dll) to this reply. If that fails, find STEVE.ZIP on ftp://lucky.syr.edu.
 

Attachments