Error handling with implicit initialization using Source property (WPF control) #4499
Unanswered
Karsten1616
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi
I'm using WebView2 (1.0.2420.47) as an optional component in my .NET Framework application.
The initialization is done just using the Source property of the WPF WebView2 control (implicit initialization as stated in the WebView2 class documentation).
The question is, how do I do error handling, for example to react to cases where the Evergreen Runtime is not installed on the computer?
I do handle the CoreWebView2InitializationCompleted event, but the initialization task started internally still causes my application to crash because there is an unobserved faulted task in case of errors.
Is there a way to handle errors correctly with the implicit initialization or do I need to switch to explicit initialization to handle errors?
Regards
Karsten
Beta Was this translation helpful? Give feedback.
All reactions