Hello
I have a ContentPage on a NavigationPage, on that ContentPage I have a Button if I click this, I navigate to a second ContentPage with a WebView on it. Till here everything works fine but if I click the Android back button or the back button in the actionbar the Android Player crashed. The Android Player is running on API19 and the Xamarin.Forms version is 1.2.3.0 that I am working on. Anybody else have this problem, do I something wrong?
Here my Example Code
App.cs
namespace WebViewTest
{
public class App
{
public static Page GetMainPage ()
{
return new NavigationPage (new StartPage ());
}
}
}
StartPage.xaml
<?xml version="1.0" encoding="UTF-8"?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" x:Class="WebViewTest.Views.StartPage">
<ContentPage.Content>
<StackLayout>
<Button Text="Go to WebView" Clicked="OnClicked" />
</StackLayout>
</ContentPage.Content>
</ContentPage>
StartPage.xaml.cs
namespace WebViewTest.Views
{
public partial class StartPage : ContentPage
{
public StartPage ()
{
InitializeComponent ();
}
async public void OnClicked(object sender, EventArgs e)
{
await Navigation.PushAsync (new WebViewPage ());
}
}
}
WebViewPage.xaml
<?xml version="1.0" encoding="UTF-8"?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" x:Class="WebViewTest.Views.WebViewPage">
<ContentPage.Content>
<WebView Source="http://www.google.ch" />
</ContentPage.Content>
</ContentPage>