In my code I have a number of "GetWindowHandle>" commands and if one fails the next one takes over etc.
However, because there is a number of different windows to search for I would like to set the time spent searching much lower than the default. The default seems to be about 5-6 seconds. So if I am searching a list of say 5 windows, and the actual window open is the last one on the list, this can take 30 seconds...
And sometimes none of the windows exist so I then display message.
What I am looking for is something like: GWH_TIMEOUT so I can set
Code: Select all
Let>GWH_TIMEOUT=1
Meanwhile I guess I can combine the search with IfNotWindowOpen or IfWindowOpen - Nope no timeout on those either.
OK let's try WaitWindowOpen - Nope this has a timeout but no IF.
Also tried using GetWindowList, thinking I can just search a list of open windows before trying to get their handle but strangely the window that does exist and shows in MS's "View System Windows" does not exist in GetWindowList output.