esullivan

WinWaitIssue

5 posts in this topic

Creating a script for fun and to help learn Autoit some.

I am creating one to download, install, and configure Origins.  I have been using WinWaitActive to wait for certain windows to be active.  However the login window and the main windows for Origins have the same title and class.  I have attached screenshots of the Window Info.

So when I WinWaitActive for the main window, it doesn't wait since the login window has the same name.  I don't want to use Sleep, as the launch time could very.  Anyway around this?

Login.JPG

Main.JPG

Share this post


Link to post
Share on other sites



I thought about that, but the window size might change.

Share this post


Link to post
Share on other sites

_WinAPI_GetWindow with a param of 6 get's the 'enabled popup' of the parent window:

$a = WinList("[CLASS:Qt5QWindowIcon]")
For $i = 1 To UBound($a)-1
    $hPopup = _WinAPI_GetWindow($a[$i][1],6)
    If IsHWnd($hPopup) Then
        ExitLoop

    EndIf

Next
ConsoleWrite($hPopup & @CRLF)

 


IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window.

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