Support Portal

for ProcessRobot and WinAutomation

Start a new topic
Not Taken

Browser is Unavailable - exception handling

If the browser is closed whilst launching, the error "browser is unavailable" will be fired. The launch internet explorer browser action's exception handling cannot handle this, nor can a exception block around the launch internet explorer browser action - the proces simply terminates. This also applies to all internet explorer related actions, where the browser becomes unavailable or terminates before or during that action, for any reason.

Suggestion to include this error in exception handling of these actions.

This post was created by the Softomotive Support Team. Thank you Mustafa Ulas Yigit for the suggestion!

4 people like this idea

This also happened to one of my processes recently when a customer went for MFA through PingID. After supplying credentials on one web page it would (sometimes) redirect to another webpage and the %Browser% web instance became void and when referenced would yield "Runtime Error: Browser is unavailable".

Really annoying to not be able to catch this exception. Any workaround?

[Stack trace]

End of inner exception stack trace ---
  at WatiN.Core.UtilityClasses.Try.NormalizeRpcException[T](Func`1 func)
  at WatiN.Core.Native.InternetExplorer.IENativeBrowser.get_CurrentPageType()
  at WatiN.Core.Native.InternetExplorer.IENativeBrowser.get_CurrentPageIsAnHtmlDocument()
  at WinAutomation.Actions.Runtime.WebAutomationRuntime.(WebBrowserInstanceVariant )
  at WinAutomation.Actions.Runtime.WebAutomationRuntime.(WebBrowserInstanceVariant )
  at WinAutomation.Actions.Runtime.WebAutomationActions.WaitForWebPageContent(Variant webBrowserInstance, Variant textToWaitFor, Variant cssSelectorForElementToWaitFor, Int32 waitForWebPageTo, Boolean timeoutSet, Int32 maxSecondsToWait)
  at WinAutomation.Actions.Runtime.WebAutomationActions.IfWebPageContainsContent(Variant webBrowserInstance, Variant textToWaitFor, Variant cssSelectorForElementToWaitFor, Int32 checkForWebPageContentMode)
  at WinAutomation.Actions.Runtime.ActualCompiledJob.<>c__DisplayClass22.<Execute>b__14(Boolean invokedThroughJumpstart)
  at WinAutomation.Actions.Runtime.ActualCompiledJob.<>c__DisplayClass22.<Execute>b__8(Boolean invokedThroughJumpstart)
  at WinAutomation.Actions.Runtime.ActualCompiledJob.Execute()
System.Runtime.InteropServices.COMException (0x80010108): The object invoked has disconnected from its clients. (Exception from HRESULT: 0x80010108 (RPC_E_DISCONNECTED))
  at SHDocVw.IWebBrowser2.get_Type()
  at WatiN.Core.Native.InternetExplorer.IENativeBrowser.()
  at WatiN.Core.UtilityClasses.Try.NormalizeRpcException[T](Func`1 func)

[/Stack trace]

2 people like this

This happens to me as well, during the Launch New Internet Explorer step.  The browser window appears to be visible, but the entire window inside the window frame is blank-white.

Login or Signup to post a comment