I'm relatively new to Xamarin, (6 mos.), and this is my first attempt at incorporating Syncfusion tools. This page is more complex than I've attempted. I've added the SfTabView to a ContentPage that also has a Xamarin ListView that incorporates a DataTemplateSelector. I see that it's a casting issue, but I'm also guessing that I've structured the page incorrectly. Any thoughts? Thanks!
Here's the error:
System.InvalidCastException: Unable to convert instance of type 'Android.Widget.TextView' to type 'Android.Support.V7.Widget.Toolbar'.
Here's the page structure:
<ContentPage>
<ContentPage.Resources>
<ResourceDictionary>
<DateTemplate x:Key="validTemplate">
<ViewCell>
<Grid>
...
</Grid>
</ViewCell>
</DateTemplate>
<DateTemplate x:Key="invalidTemplate">
<ViewCell>
<Grid>
...
</Grid>
</ViewCell>
</DateTemplate>
</ResourceDictionary>
</ContentPage.Resources>
<ContentPage.Content>
<StackLayout>
<tabView:SfTabView />
<ListView ItemTemplate="{StaticResource TemplateSelector}" />
</StackLayout>
</ContentPage.Content>
</ContentPage>
For the <tabView:SfTabView /> I'm using the sample code from the Syncfusion site:
<tabView:SfTabView >
<tabView:SfTabItem Title="Call">
<tabView:SfTabItem.Content>
<Grid BackgroundColor="Red" x:Name="AllContactsGrid" />
</tabView:SfTabItem.Content>
</tabView:SfTabItem>
<tabView:SfTabItem Title="Favorites">
<tabView:SfTabItem.Content>
<Grid BackgroundColor="Green" x:Name="FavoritesGrid" />
</tabView:SfTabItem.Content>
</tabView:SfTabItem>
<tabView:SfTabItem Title="Contacts">
<tabView:SfTabItem.Content>
<Grid BackgroundColor="Blue" x:Name="ContactsGrid" />
</tabView:SfTabItem.Content>
</tabView:SfTabItem>
</tabView:SfTabView>