Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 77050

OnAppearing() not working anymore

$
0
0

I don't know what else to mention besides this but OnAppearing isn't firing anymore. I am using TabbedPage but I was using TabbedPage before when OnAppearing was working as well.

Anyways here is what I am trying to achieve and maybe there may be another way to implement it.

The master page is a tabbed page containing Page C. Now Page C is an empty carousel page in which its OnAppearing() populates it like so:
Children.Add(new PersonPage()) //run 10 times so Page C is now a carousel page with 10 pages

So now what I am trying to do is when the user is on the 8th page (the 8th PersonPage) in the carousel page, add more pages to the carousel page so that the user does not reach the end of the carousel page. An infinite scrollable carousel page.

I basically added a flag to the 8th page and in the PersonPage() onAppearing(), checked whether the flag is set and then called:
parent.Children.Add(new PersonPage())

This was working but it isn't anymore. It seems to be because the PersonPage() OnAppearing() isn't firing anymore. I tested this by calling a DisplayAlert() which didn't show up.

Has anyone done anything similar?


Viewing all articles
Browse latest Browse all 77050

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>