I have a WebView in my .Maui app that displays a forum for users to use with my app. But I've noticed that if anyone posts a link that requires the WebView to open the link in a new window, nothing happens. My initial thought was to capture the URL of the link the user selects using the Navigating event, but it is never triggered for these links, only for the ones that open their destination within the WebView itself. Has anyone here faced this dilemma and what did you do to solve it?
Hwew's the code I've tried so far, which fired fine for links that don't need to open in a new window, but ignores the links that do:
public BlenderPage()
{
InitializeComponent();
BlenderWebview.Navigating += BlenderWebview_Navigating;
}
private void BlenderWebview_Navigating(object sender, WebNavigatingEventArgs e)
{
Console.WriteLine(e.Url.ToString());
}
Also, this issue is happening with the .NET Maui android app version