WinBatch Tech Support Home

Database Search

If you can't find the information using the categories below, post a question over in our WinBatch Tech Support Forum.

TechHome

EXAMPLES FROM USERS

Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.

Check if Window with Blank Title Exists

 Keywords: WinTitle DllHwnd WinIdGet WinGetActive cWndbyWndSpec WinExist

Question:

I have an application that if the license is exceeded a window will popup, but there is no title to the window. What other options do i have, or is there still a way to use WinExist?

I have used roboscripter to get some info...

ControlHandle=cWndByWndSpec("DialogClass32","runw",13,25,0,0,28,0,29,0,0,31,32,33,34,0) cSetFocus(ControlHandle) ; Activates Window

Could something from there be used? Or is a better method out there? Thanks in Advance

Answer:

In WinBatch windows can be referenced by:
  1. Name - WinTitle or DllHwnd
  2. Window ID - WinIdGet ( see also WinGetActive)
  3. Window Specification - cWndbyWndSpec
For your situatuion, I recommend using cWndByWndSpec to check if the window is available.

;Add the control manager extender.
AddExtender("wwctl44i.dll")
; Get the handle by the window specification.
hWnd = cWndByWndSpec("DialogClass32","runw",13,25,0,0,28,0,29,0,0,31,32,33,34,0)
If hWnd == 0
   Pause('Notice','The window does not currently exist')
Else
   Pause('Notice','The window does exist')
EndIf

Article ID:   W17564
Filename:   Check if Window with Blank Title Exists.txt
File Created: 2013:08:13:09:31:56
Last Updated: 2013:08:13:09:31:56