Welcome Guest Search | Active Topics | Sign In | Register

How to properly handle WebView.RenderUnresponsive event? Options
Daniel
Posted: Thursday, April 6, 2017 2:43:16 AM
Rank: Newbie
Groups: Member

Joined: 3/29/2017
Posts: 1
Hello! It is a very rare situation when WebView "freezes" and WebView.RenderUnresponsive event fired. And I don't know how to repeat it for debug purposes. The question is how to properly handle this situation to let application, that uses WebView, continue working. Is it right way to create a new WebView inside WebView.RenderUnresponsive event handler and assign it to the WebControl that hosts this WebView (in WPF application)?
eo_support
Posted: Thursday, April 6, 2017 1:14:37 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,229
Hi,

This event usually occurs when your web page has runaway JavaScript code that does not return for a long period of time (for example, an infinite loop). The only way to recover from this situation is to kill the WebView. WebView.RenderUnresponsive provides you the opportunity to do so.The typical handling of this event is to ask the user if he wants to continue to wait. If user answers yes then do nothing, If user answers no, then you can recreate a new WebView and assign it to the WebControl. The old WebView will be automatically destroyed.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.