Ask a Question

How to resume execution after event handler?

Frequent Contributor

How to resume execution after event handler?

I want to handle unexpected windows during my test by closing the unexpected window and resuming my test execution.


Without an event handler the log shows three errors:

1) Unexpected window

2) The operation cannot be completed due to an unexpected window

3) Script execution was interrupted.


I have written an onUnextectedWindow event handler that closes the unexpected window. It closes the window successfully but test execution still halts. The log shows that my event handle was called but still shows errors 2 & 3.


What do I have to do to resume execution after handling the onUnextectedWindow event?


Many Thanks.

Frequent Contributor

Sorry - I've figured it out.

You have to go to the project options and under "On unexpected window" uncheck "Stop execution"

Showing results for 
Search instead for 
Did you mean: