We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

IList

If I set the DataSource to an IList, and then change values in the IList, how does the ggrid control known when these changes occur, so that I can redraw accordingly?!

1 Reply

AD Administrator Syncfusion Team December 16, 2004 04:01 PM UTC

Hi Dominic, you need to implement IBindingList and raise ListChanged events. The grid listens to the ListChanged events and will synchronize itsself with the structure accordingly. See the StrongTypedList as an example. If you also specify grid.Engine.InvalidateAllWhenListChanged = false; then the grid will only paint those records that were changed. You could for example do a batch of updates (raising multiple ListChanged events) and then call grid.Update() once the batch of updates is finished. It is important that the ListChanged event is raised right after you made the change to the datasource. It needs to be raised immediately after each change if you perform multiple changes. Stefan

Loader.
Live Chat Icon For mobile
Up arrow icon