locked
WebView crashes on Windows 8.1

    Question

  • Hi,

    I am using WebView to display web content in my app. I provide back/forward buttons to allow backward/forward navigation in the WebView. On press of back button I simply call WebView.GoBack() which is obviously protected by CanGoBack. Similarly I call WebView.GoForward() on press of Forward button.

    Now when I browser few websites and navigate Back and Forward few times the application crashes. I am not getting anything in the UnhandleException callback neither do I catch any exception on marking everything in Debug -> Exceptions.

    I tested this behavior with a sample app too. Here's code for that. To reproduce, browse http://www.google.com first then browse http://www.bbc.com and alternate between these with Back and Forward buttons little fast. Application will crash in no time.

    Is this a known bug with WebView or am I doing something wrong?

    Regards,

    Vinay

    Wednesday, December 3, 2014 9:21 AM

Answers

  • This is a known bug which was fixed previously, and this may be a regression. I'm going to talk to the people who own WebView about this.

    Matt Small - Microsoft Escalation Engineer - Forum Moderator
    If my reply answers your question, please mark this post as answered.

    NOTE: If I ask for code, please provide something that I can drop directly into a project and run (including XAML), or an actual application project. I'm trying to help a lot of people, so I don't have time to figure out weird snippets with undefined objects and unknown namespaces.

    • Marked as answer by VinayPPatil Thursday, December 4, 2014 6:25 AM
    Wednesday, December 3, 2014 4:36 PM
    Moderator

All replies

  • Hi Vinay - I downloaded your code and can reproduce the problem.  I'm investigating now and will update when I know more.

    Matt Small - Microsoft Escalation Engineer - Forum Moderator
    If my reply answers your question, please mark this post as answered.

    NOTE: If I ask for code, please provide something that I can drop directly into a project and run (including XAML), or an actual application project. I'm trying to help a lot of people, so I don't have time to figure out weird snippets with undefined objects and unknown namespaces.

    Wednesday, December 3, 2014 3:58 PM
    Moderator
  • This is a known bug which was fixed previously, and this may be a regression. I'm going to talk to the people who own WebView about this.

    Matt Small - Microsoft Escalation Engineer - Forum Moderator
    If my reply answers your question, please mark this post as answered.

    NOTE: If I ask for code, please provide something that I can drop directly into a project and run (including XAML), or an actual application project. I'm trying to help a lot of people, so I don't have time to figure out weird snippets with undefined objects and unknown namespaces.

    • Marked as answer by VinayPPatil Thursday, December 4, 2014 6:25 AM
    Wednesday, December 3, 2014 4:36 PM
    Moderator
  • Thanks for your time and effort Matt. Do let us know of when can we expect a fix on this.

    Regards,

    Vinay

    Thursday, December 4, 2014 6:28 AM
  • I also have the same problem with one of my windows store apps when using the WebView control (crashes the entire app intermittently GoBack() and GoForward() code is triggered). As stated by others, the error cannot be trapped as an unhandled exception as it bubbles up from the WebView control error source. I consider this problem a serious issue and a show stopper for even using the WebView control in any app in the future unless this gets resolved. It doesn't seem to be a very high priority since the last post appears to be on 12/3/14 and the issue remains unresolved.  Surely there must be a way to redesign the WebView control to trap script type errors internally and at minimum, throw it back up to the app hosting the control as an exception type that can be handled in the app hosting the WebView control. Is any person or group currently working to resolve this issue?
    Wednesday, April 8, 2015 10:07 PM
  • Since it's not fixed now, it will most likely be resolved in Windows 10.

    Matt Small - Microsoft Escalation Engineer - Forum Moderator
    If my reply answers your question, please mark this post as answered.

    NOTE: If I ask for code, please provide something that I can drop directly into a project and run (including XAML), or an actual application project. I'm trying to help a lot of people, so I don't have time to figure out weird snippets with undefined objects and unknown namespaces.

    Thursday, April 9, 2015 1:16 PM
    Moderator
  • Hello Matt,

    Since the Webview is a control available in Visual Studio I assumed that the fix would be available as an update for all Visual Studio versions as soon as possible. I don't see the association with Windows 10 as being the key milestone for 'probably' providing a fix for this issue unless it's a browser or OS version specific problem, but even then any web related control design should still internally provide script error trapping/rethrow as  an exception type that can be handled by the host app for any current OS or browser version. For those of us currently using the Webview control in our published apps, and there are many, that news doesn't provide much comfort and certainly won't help any app's reviews. What's particularly frustrating is that in an earlier post you stated that this problem might be a regression (fixed earlier and then broken again). If that's the case then why wait until 'probably' Windows 10? I'm very disappointed that the Microsoft team is obviously not taking this issue seriously. Most of us don't like to leave our apps sitting in the store with a known bug, especially one that we cannot personally fix. If I can't get a more definitive timeline I'll be forced to remove any published app from the store currently using this control.

     In any case, thank you very much for your time, responses, and assistance.

    Thursday, April 16, 2015 4:10 PM
  • I agree that this is a bad scenario.  We know what the issue is, but it wasn't a regression, it just was never fixed in Windows 8.1. I don't know the business justification behind not fixing it at this point.  I will say that Windows 10 is the focus of all development at this time.  I don't have access into the Windows 10 bug database right now to tell you that it's been resolved, but expect to have it soon, and will ensure that we raise the priority of this in the case that it's still an issue after the Windows 10 build is released at //BUILD in a couple of weeks.

    Matt Small - Microsoft Escalation Engineer - Forum Moderator
    If my reply answers your question, please mark this post as answered.

    NOTE: If I ask for code, please provide something that I can drop directly into a project and run (including XAML), or an actual application project. I'm trying to help a lot of people, so I don't have time to figure out weird snippets with undefined objects and unknown namespaces.

    Thursday, April 16, 2015 4:17 PM
    Moderator
  • Thank you very much Matt. Your time and effort and prompt responses are greatly appreciated by all.
    Thursday, April 16, 2015 8:46 PM