sada
sada

Reputation: 693

MudBlazor DataGrid NoRecordsContent

Can somebody help me how I can give parameter to NoRecordsContent parameter of DataGrid, please. I would like stylized text display when there's no data to be displayed in the grid.

Upvotes: 1

Views: 720

Answers (1)

Dimitris Maragkos
Dimitris Maragkos

Reputation: 11392

NoRecordsContent is a RenderFragment parameter. You use it like this:

<MudDataGrid ...>
    ...
    <NoRecordsContent>
        No data
    </NoRecordsContent>
</MudDataGrid>

You can put any html content (or other Blazor components) inside <NoRecordsContent></NoRecordsContent>: https://try.mudblazor.com/snippet/mkwIudENKnGKnhrI

Upvotes: 5

Related Questions