Duplicated
Last Updated: 02 Mar 2020 13:27 by ADMIN
Olivier
Created on: 07 Aug 2019 09:33
Category: Grid
Type: Bug Report
0
Refresh issue on TelerikGrid when adding item from a simple button

Hello,

I'm trying the grid component and I'm able to add a row to the grid using the embbed editor. But I wanted to add an item externally to the list:


<button @onclick="@MyClick">Add item</button>

 

void MyClick()
{
    MyData.Add(new SampleData() { ID = 46, Name = "from click" });
    StateHasChanged();
}

The new line does not appear on the grid but if I add a second item through the embbed editor then I get the 2 items!

I also try to replace the List<MyData> by an ObservableCollection<MyData> unsuccessfully.

 

Thanks & regards,

 

Duplicated
This item is a duplicate of an already existing item. You can find the original item here:
3 comments
ADMIN
Marin Bratanov
Posted on: 09 Aug 2019 06:40
Hi Olivier,

Support for observable collection will be available in our next feature release. Hopefully, we will also get a .Refresh() method then too, in case you don't use an observable, but that is still subject to planning, workload and prioritization.


Regards,
Marin Bratanov
Progress Telerik UI for Blazor
Olivier
Posted on: 09 Aug 2019 06:35

Hi Marin,

Thanks for your answer! Sorry I missed the duplicate.. Hope we get a fix soon :)

Thanks & regards,

ADMIN
Marin Bratanov
Posted on: 08 Aug 2019 04:29
Hi Olivier,

This is discussed in detail in the following issue: https://feedback.telerik.com/blazor/1409112-the-grid-does-not-update-on-data-source-change. Pleas Follow that for status updates, as I am closing this one as a duplicate.

 


Regards,
Marin Bratanov
Progress Telerik UI for Blazor