Home > OS >  Xamarin.UWP CarouselPage OnAppearing() bug
Xamarin.UWP CarouselPage OnAppearing() bug

Time:10-24

App.xaml.cs

MainPage = new NavigationPage(new Home());

Home.xaml.cs

    public Home()
    {
        Children.Insert(0,new CarPage1());
        Children.Insert(1,new CarPage2());
        Children.Insert(2,new CarPage3());
        CurrentPage = Children[1];
    }

CarPage1.xaml.cs

    protected override void OnAppearing()
    {
        base.OnAppearing();
        DisplayAlert("Page1", null, "ok");
    }

CarPage2.xaml.cs

    protected override void OnAppearing()
    {
        base.OnAppearing();
        DisplayAlert("Page2", null, "ok");
    }

CarPage3.xaml.cs

    protected override void OnAppearing()
    {
        base.OnAppearing();
        DisplayAlert("Page3", null, "ok");
    }

Run UWP Page2 alert show. enter image description here

click ok why Page1 alert show? enter image description here

click UWP left symbol why no Page1 alert show? enter image description here

Run Xamarin.Android work fine!!

CodePudding user response:

Yes, it is just the case as you said.

And I have created a new issue about this problem. You can follow it up here: https://github.com/xamarin/Xamarin.Forms/issues/15577 .

Thanks for your support and feedback for xamarin.

Have a nice day.

  • Related