Radzen DataGrid Loading Indicator not showing up

I'm using the RadzenDataGrid isLoading property to show the loading indicator as documented here
Blazor DataGrid custom data-binding (radzen.com)

But the loading indicator is not showing up

<RadzenDataGrid TItem="PortfolioWrapper"
                Data="@portfolioWrappers"
                AllowPaging="true"
                PageSize="20"
                AllowSorting="true"
                AllowFiltering="true"
                AllowColumnResize="true"
                Count="@assetProxyCount"
                FilterMode="FilterMode.Simple"
                IsLoading="@isLoading"
                @ref="grid"
                LoadData="@LoadData"
                FilterCaseSensitivity="FilterCaseSensitivity.CaseInsensitive">

    <Columns>
    ........
 protected async Task LoadData()
        {
            isLoading = true;
           //dostuff
            isLoading = false;
       }

Please advice

I have the same problem on Server side...

Thanks , but this does not fix the issue.

Well, it works as expected on our demo. Check what's different in your case.

Well didn't work either on my code also.
I have the following code

protected override async Task OnAfterRenderAsync(bool firstRender)
{
if (firstRender)
{
isLoading = true;
await Task.Yield();
ADUsers = await AzureADService.GetADUsersAsync();
isLoading = false;
StateHasChanged();
}
}

but instead of the loading spinner I am getting the "No records to display" message

1 Like

We recently ran into this issue when calling a method to load the datagrid from a base class. Oddly enough the spinner does work as expected when the method is called from a button click on the page, but simply refused to work when called from the base class.

By adding a StateHasChanged method call before the Yeild fixed the issue for us.

i.e.

private async Task GetReportData()
    {
        dataGridLoading = true;
        StateHasChanged();
        await Task.Yield();