Open meshawn opened 5 years ago
Having this method would be nice, but a work around is casting the view. Feel free to close this one.
@meshawn how did you do this? Did it work with earlier windows versions? E.g. Win 7?
You just need to cast the web view to WebBrowser: WebBrowser ie = webViewCompatible.View as WebBrowser; ie.Navigate(uri, null, null, string.Format("User-Agent: {0}\r\n", agent));
Casting to WebBrowser does not work for me.
private Microsoft.Toolkit.Wpf.UI.Controls.WebViewCompatible webViewCompatible1;
var ie = webViewCompatible1.View as System.Windows.Forms.WebBrowser;;
does not compile with
Cannot convert type 'System.Windows.FrameworkElement' to 'System.Windows.Forms.WebBrowser' via a reference conversion, boxing conversion, unboxing conversion, wrapping conversion, or null type conversion
Casting to WebBrowser does not work for me.
private Microsoft.Toolkit.Wpf.UI.Controls.WebViewCompatible webViewCompatible1; var ie = webViewCompatible1.View as System.Windows.Forms.WebBrowser;;
does not compile with
Cannot convert type 'System.Windows.FrameworkElement' to 'System.Windows.Forms.WebBrowser' via a reference conversion, boxing conversion, unboxing conversion, wrapping conversion, or null type conversion
I figured it out. I was using Microsoft.Toolkit.Wpf.UI.Controls.WebView instead of Microsoft.Toolkit.Forms.UI.Controls.WebView.
I'm submitting a...
Feature request (UserVoice request: )
Current behavior
This method is missing
Expected behavior
Have the ability to call WebViewCompatible.Navigate(Uri requestUri, HttpMethod httpMethod, string content = null, IEnumerable<KeyValuePair<string, string>> headers = null);
Environment