- Home
- Forum
- Xamarin.Forms
- sfTabView MVVM Nested
sfTabView MVVM Nested
Hello,
i'm would to render a content page that contains a sfTabView.
I'm Populating items by MVVM settings Items={Binding Items}, but if one of these Items is a ContentPage with sfTabView not work and my app freeze and display
nothing.
Can you help me?
SIGN IN To post a reply.
5 Replies
1 reply marked as answer
SS
Suganya Sethuraman
Syncfusion Team
April 16, 2021 11:53 AM UTC
Hi Grandinote,
Greetings from Syncfusion.
We have analyzed the reported issue. We have prepared a sample using nested SfTabView in the MVVM pattern. But we could not be able to reproduce the issue. Please have a sample for your reference,
Sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/TestTabView-1740119839
Could you please let us know that the provided sample resolved your issue? If not, please modify our sample and revert us to check on it and provide you the solution as soon as possible.
Regards,
Suganya Sethuraman.
Greetings from Syncfusion.
We have analyzed the reported issue. We have prepared a sample using nested SfTabView in the MVVM pattern. But we could not be able to reproduce the issue. Please have a sample for your reference,
Sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/TestTabView-1740119839
Could you please let us know that the provided sample resolved your issue? If not, please modify our sample and revert us to check on it and provide you the solution as soon as possible.
Regards,
Suganya Sethuraman.
Marked as answer
GS
Grandinote srls
April 16, 2021 12:21 PM UTC
Hi Suganya ,
thank you so much for your support.
This Sample resolved my issue.
SS
Suganya Sethuraman
Syncfusion Team
April 19, 2021 09:48 AM UTC
Hi Grandinote,
Thanks for the update.
We are glad to know that the given solution works. Please let us know if you need any further assistance.
Regards,
Suganya Sethuraman.
Thanks for the update.
We are glad to know that the given solution works. Please let us know if you need any further assistance.
Regards,
Suganya Sethuraman.
GS
Grandinote srls
April 27, 2021 12:21 PM UTC
Hello to everyone,
in the example you gave me(https://www.syncfusion.com/downloads/support/directtrac/general/ze/TestTabView-1740119839)
everything works correctly, but I would need an example where the Page1 of your project is also loaded via mvvm and not in xaml.
I tried it but it always gives me an error (Element: Syncfusion.XForms.TabView.SfTabView is already a child of mynamespace.MyTab.) and doesn't load the page.
If I use xaml it works instead.
Can you help me please?
SS
Suganya Sethuraman
Syncfusion Team
April 28, 2021 07:42 AM UTC
Hi Grandinote,
Thanks for the update.
We have analyzed your requirement. We don’t set ContentPage to the content of SfTabView. So, We have achieved your requirement using ContentView as shown in the below code snippet,
Code snippet
Thanks for the update.
We have analyzed your requirement. We don’t set ContentPage to the content of SfTabView. So, We have achieved your requirement using ContentView as shown in the below code snippet,
Code snippet
|
<tabview:SfTabView x:Name="tabView">
<tabview:SfTabItem Title="Tab1">
<tabview:SfTabItem.Content>
<Grid>
<local:Page1 />
</Grid>
</tabview:SfTabItem.Content>
</tabview:SfTabItem>
<tabview:SfTabItem Title="Tab2">
<tabview:SfTabItem.Content>
<Grid>
<local:Page2 />
</Grid>
</tabview:SfTabItem.Content>
</tabview:SfTabItem>
</tabview:SfTabView> |
Please have a sample for your reference,
Sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/TabViewXaml1154587767
Please check if the sample satisfies your requirement and let us know if you have any concerns.
Regards,
Suganya Sethuraman.
SIGN IN To post a reply.
- 5 Replies
- 2 Participants
- Marked answer
-
GS Grandinote srls
- Apr 15, 2021 01:44 PM UTC
- Apr 28, 2021 07:42 AM UTC