question

VasanthakumarM-3635 avatar image
0 Votes"
VasanthakumarM-3635 asked ColeXia-MSFT commented

Xamarin CustomtoolKit Navigating Page

Hi Techie,
I try to use the Xamarin custom toolkit for the Tabview option. But I couldn't navigate the different pages like Home.XAML, Notification.XAML.


dotnet-csharpdotnet-xamarin
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

ColeXia-MSFT avatar image
0 Votes"
ColeXia-MSFT answered ColeXia-MSFT commented

Hello,

Welcome to Microsoft Q&A!

Check TabViewItem.Content in this link , it only supports View not Page .

Your can create a new ContentView and set as below .

<xct:TabView
                TabStripPlacement="Bottom"
                TabStripBackgroundColor="Blue"
                TabStripHeight="60"
                TabIndicatorColor="Yellow"
                TabContentBackgroundColor="Yellow">

                <xct:TabViewItem
                    Icon="triangle.png"
                    Text="Tab 1"
                    TextColor="White"
                    TextColorSelected="Yellow"
                    FontSize="12">
                    <local : YourCustomContentView>
                </xct:TabViewItem>
</xct:TabView>


If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


· 6
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

@ColeXia-MSFT


86690-image.png




I'm getting an error. "property 'content' does not support values of type"

0 Votes 0 ·
image.png (25.1 KiB)

What is Home ? Is it a ContentView ?

0 Votes 0 ·

Check my answer above , TabViewItem.Content only supports View , we can not set contentPage as its content .

0 Votes 0 ·

@ColeXia-MSFT, Please go through the error. If I add to contentView I'm facing an issue like this.


87316-image.png

87342-image.png

87392-image.png

But in contentView, I Can't call the onAppearing, DisplayAlert, etc., How to Overcome this problem.


0 Votes 0 ·
image.png (7.3 KiB)
image.png (5.0 KiB)
image.png (9.3 KiB)

What you need is TabbedPage not Tabview .


0 Votes 0 ·