-
Notifications
You must be signed in to change notification settings - Fork 477
[Bug] [MauiCompat] TabView component is not working #1873
Comments
it may start work with .NET MAUI 6.0.400 |
Can anyone confirm if TabView already works with this version? |
I was able to make it work at least somehow by adding the following code: builder
.UseMauiCompatibility()
.ConfigureEffects(x => x.AddCompatibilityEffects(typeof(VisualFeedbackEffect).Assembly))
.ConfigureMauiHandlers(handlers =>
{
// Register ALL handlers in the Xamarin Community Toolkit assembly
handlers.AddCompatibilityRenderers(typeof(Xamarin.CommunityToolkit.UI.Views.MediaElementRenderer).Assembly);
}); But the tab strip is buggy, it shows the first element only for me. <xct:TabView BackgroundColor="White" TabStripBackgroundColor="LightGray">
<xct:TabViewItem Text="First">
<Label Text="Doesn't work."/>
</xct:TabViewItem>
<xct:TabViewItem Text="Second">
<Label Text="Does it?"/>
</xct:TabViewItem>
<xct:TabViewItem Text="Third">
<Label Text="Nope"/>
</xct:TabViewItem>
</xct:TabView> |
I have tried and getting below error;
how to solve this error? |
Any update on this? ++ |
I have seen TabView was not yet implemented in the .NET MAUI Community Toolkit, so I was hoping it would work using the MauiCompat version of the Xamarin Community Toolkit, but with 2.0.2-preview1013 I have the same error as mentioned above:
|
Any update on this? |
Any update? |
We do not have plans to migrate TabView. You can use this alternatives: https://vladislavantonyuk.github.io/articles/Mastering-Composite-Controls-in-.NET-MAUI%3A-Building-a-TabView-from-Scratch |
Description
Hello,
I tryed to use the TabView components in a Maui project
, using MauiCompat, but i was unable to make it works.
I created a basic project from a basic Maui project with the nugget Xamarin.CommunityToolkit.MauiCompat added and the MainPage xaml code has been repalced with the TabView sample code, so there is no complexity it's just a basic project.
Here is the error i obtained
_
Microsoft.Maui.Platform.ToPlatformException: 'Microsoft.Maui.Controls.Compatibility.RendererToHandlerShim found for Microsoft.Maui.Controls.Compatibility.Grid is incompatible'
Stack Trace
Link to Reproduction Sample
A zip file is attached with the project
MauiTest.zip
Expected Behavior
The main page should display and the TabView should appear.
Actual Behavior
A black screen is displayed and an exception occure.
Basic Information
The text was updated successfully, but these errors were encountered: