Closed chentotal closed 6 years ago
In App.xaml.cs file in App method try change MainPage = tabs;
to MainPage = new NavigationPage(tabs);
@bkosmowski Thanks, it works.
Updated to the last version of Xamarin Forms and BottomTabbedPage and now I get PopToRootAsync is not supported...
when changed tabs. There is some workaround?
Did you try change MainPage = tabs;
to MainPage = new NavigationPage(tabs);
like I mentioned in first comment?
Hi! I'm using Prism and the first Navigation is
await NavigationService.NavigateAsync("NavigationPage/LoginPage");
Is this similar to MainPage = new NavigationPage(tabs)
?
I got a switch page problem. When switch page, it always pop to root, so I downloaded demo for test. And I found out demo has same problem and it crash.
Call Stack
0x65 in Naxam.Controls.Platform.Droid.Utils.BottomTabbedRendererUtils.SwitchPage at C:\Users\total\Downloads\bottomtabbedpage-xamarin-forms\BottomTabbedPage.Droid\Utils\SizeUtils.cs:81,13 C# 0x3 in Naxam.Controls.Platform.Droid.BottomTabbedRenderer.OnNavigationItemSelected at C:\Users\total\Downloads\bottomtabbedpage-xamarin-forms\BottomTabbedPage.Droid\BottomTabbedRenderer.Tabs.cs:31,13 C# [External Code] 0x84 in Naxam.Controls.Platform.Droid.Utils.BottomTabbedRendererUtils.EnsureTabIndex at C:\Users\total\Downloads\bottomtabbedpage-xamarin-forms\BottomTabbedPage.Droid\Utils\SizeUtils.cs:50,17 C# 0x61 in Naxam.Controls.Platform.Droid.Utils.BottomTabbedRendererUtils.ChangePage at C:\Users\total\Downloads\bottomtabbedpage-xamarin-forms\BottomTabbedPage.Droid\Utils\SizeUtils.cs:317,13 C# 0x9 in Naxam.Controls.Platform.Droid.BottomTabbedRenderer.SwitchContent at C:\Users\total\Downloads\bottomtabbedpage-xamarin-forms\BottomTabbedPage.Droid\BottomTabbedRenderer.cs:166,13 C# 0x2B in Naxam.Controls.Platform.Droid.BottomTabbedRenderer.OnElementPropertyChanged at C:\Users\total\Downloads\bottomtabbedpage-xamarin-forms\BottomTabbedPage.Droid\BottomTabbedRenderer.cs:89,17 C# 0xB1 in Naxam.Controls.Platform.Droid.Utils.BottomTabbedRendererUtils.SwitchPage at C:\Users\total\Downloads\bottomtabbedpage-xamarin-forms\BottomTabbedPage.Droid\Utils\SizeUtils.cs:87,17 C# 0x3 in Naxam.Controls.Platform.Droid.BottomTabbedRenderer.OnNavigationItemSelected at C:\Users\total\Downloads\bottomtabbedpage-xamarin-forms\BottomTabbedPage.Droid\BottomTabbedRenderer.Tabs.cs:31,13 C#
Main cause is when switch page
public static void SwitchPage(this BottomTabbedRenderer renderer, IMenuItem item)
would be called twice.