C
C#4mo ago
DaClownie

Unable to get tabs to show after initial login screen for MAUI app

Anyone have any experience with .NET MAUI tabbed pages? I can not for the life of me get a TabBar to appear correctly after having a login cycle happen. It loads the content for the page, but the TabBar is messed up. If I comment out the ShellContent for the login page, then the TabBar shows up, but it won't load the login.
<ShellContent
Title="MainPage"
ContentTemplate="{DataTemplate pages:MainPage}"
Route="MainPage"
Shell.FlyoutItemIsVisible="False"
Shell.NavBarIsVisible="False"/>
<TabBar>
<Tab Title="Track"
Icon="{mi:Material Icon=School}"
Route="TermsPage">
<ShellContent ContentTemplate="{DataTemplate pages:TermsPage}" />
</Tab>
<Tab Title="Report"
Icon="{mi:Material Icon=ContentPaste}"
Route="ReportsPage">
<ShellContent ContentTemplate="{DataTemplate pages:ReportsPage}" />
</Tab>
<Tab Title="Profile"
Icon="{mi:Material Icon=ManageAccounts}"
Route="ProfilePage">
<ShellContent ContentTemplate="{DataTemplate pages:ProfilePage}" />
</Tab>
</TabBar>
<ShellContent
Title="MainPage"
ContentTemplate="{DataTemplate pages:MainPage}"
Route="MainPage"
Shell.FlyoutItemIsVisible="False"
Shell.NavBarIsVisible="False"/>
<TabBar>
<Tab Title="Track"
Icon="{mi:Material Icon=School}"
Route="TermsPage">
<ShellContent ContentTemplate="{DataTemplate pages:TermsPage}" />
</Tab>
<Tab Title="Report"
Icon="{mi:Material Icon=ContentPaste}"
Route="ReportsPage">
<ShellContent ContentTemplate="{DataTemplate pages:ReportsPage}" />
</Tab>
<Tab Title="Profile"
Icon="{mi:Material Icon=ManageAccounts}"
Route="ProfilePage">
<ShellContent ContentTemplate="{DataTemplate pages:ProfilePage}" />
</Tab>
</TabBar>
With the ShellContent at the top commented out, I get my NavBar, but no login page (MainPage)
No description
No description
1 Reply
DaClownie
DaClownieOP4mo ago
Oh I forgot, the mention, that janky "MainPage" link at the bottom of the first screenshot will actually navigate me back to the MainPage
Want results from more Discord servers?
Add your server