Quantcast
Channel: Active questions tagged blazor - Stack Overflow
Viewing all articles
Browse latest Browse all 4839

Inherit from "FluentUI Blazor DataGrid"

$
0
0

How can a component inherit from "FluentUI Blazor DataGrid"? I get the following error when I try to inherit from "FluentUI Blazor DataGrid", anyone have experience with this?

Error:

CS0411
The type arguments for method 'TypeInference.CreatePropertyColumn_7<TGridItem, TProp>(RenderTreeBuilder, int, int, Expression<Func<TGridItem, TProp>>, int, bool?, int, Align)' cannot be inferred from the usage.
Try specifying the type arguments explicitly

InheritGrid.razor:

@typeparam TItem@inherits FluentDataGrid<TItem>@{      base.BuildRenderTree(__builder);}

InheritGrid.razor.cs:

namespace TishtarUI.Test{    public partial class InheritGrid<TItem> : FluentDataGrid<TItem>    {    }}

Home.razor:

<InheritGrid Items="@Persons" TGridItem="Person"><PropertyColumn Property="@(p => p.FirstName)" Sortable="true" Align="Align.Start" /></InheritGrid>

Viewing all articles
Browse latest Browse all 4839

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>