If an ObservableCollection is bound as DataSource to an DataGrid
and fires the CollectionChanged Reset action the Grid doesn’t refresh.
Hi Jeevakanth,
we are currently using the Syncfusion NuGet version
18.2.0.55. It does not work correctly under certain circumstances. In this context,
we were able to reproduce two cases in the demo app (attached zip file).
1) Data in the grid are no longer displayed as soon as you
leave the page and call it up again
protected
override async Task OnAfterRenderAsync(bool firstRender)
{
if
(firstRender)
{
await
Task.Delay(250);
await
Task.Run(() =>
{
Model.GridData.Clear();
Model.GridData.AddRange(OrdersDetailsObserveData.GetRecords());
});
}
}
Start application -> navigate to the Dropdown page -> navigate back to the grid page => grid remains empty
In more complex navigation scenarios in my application, this happens the first time the page is called up.
2) Data in the grid are not updated when the button in the context menu is clicked (Button on the page works properly)
Start application -> click on the button at the top right "Change Grid DataSource (not working)" => Grid is not updated
I did not have such problems with Telerik's DataGrid Blazor
component.