Capturing the URL if we don\'t know what window we
There are other posts on URL capturing, but this is slightly different, and I didn't want to hijack.
I want to check for an error message by looking at the url. I don't know what window is there, because it is either my usual window or the window called "Error Page".
If the url is the following:
…then I want to generate the appropriate user message and then take certain actions to navigate away, and continue testing other functionality.
I could possibly just capture the URL, or the “Text” property of the window, except that these require the WINDOW NAME, which is unknown. Any call I make needs to have the window name in it.
If Window("Error Page").Property("Text") = "Error Page" Then println("Reached Error Page")
This assumes I already know I am on the Error Page.
How do I capture the browser URL or the "Inner Text" without knowing the Window control Name?
Or is there a better suggestion?
Re: Capturing the URL if we don\'t know what window we
I learned that
looks at the browser window without needing to know the name of it. This command above can then return the name.