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
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Retrieving Changed Rows in Heirarchal grid

Thread ID:





25459 Feb 27,2005 07:40 PM UTC Feb 28,2005 02:32 AM UTC WinForms 4
Tags: GridControl
Daniel Byers
Asked On February 27, 2005 07:40 PM UTC

I have a GDBC with three levels of nested relations. In each level, the user is able to mark records for additional processing with a checkbox. How do I retrieve a collection of all of the changed rows for each of the heirarchies? Additionally, which event(s) do I need to hook into to track the changes as they are being made (in order to display a count of selected record for each level)? TIA

Daniel Byers
Replied On February 27, 2005 08:05 PM UTC

This appears to work for retrieving the changed rows(is it the optimal method?). However, the EndEdit() is not writing the last changes to the buffer if my checkbox in the GDBC still has focus: gridAdDrills.CurrentCell.EndEdit() ; DataSet ds = (DataSet) gridAdDrills.DataSource ; DataView dv = new DataView(ds.Tables["BrandVariants"],"","",DataViewRowState.ModifiedCurrent) ;

Administrator [Syncfusion]
Replied On February 27, 2005 08:41 PM UTC

The lists associated with the child tables are dynamic. They come and go when you expand and collapse the parent rows. So, one way to track the changes is to subscribe to the ListChanged event in RowExpanded and unsubscribe in RowCollapsing. A sampler way (if it serves your purposes) is to subscribe to the grid.RowSaved event. In that event, you can use the GridBoundRecordState to get information about the DataRow that changed. But it would be up to use to maintain a list of such changes for whatever purpose you need them. Here is a little sample that just displays the changes on the Console, you would need to cache the information you want to track. http://www.syncfusion.com/Support/user/uploads/GDBG_HierarchyChanges_84da9f68.zip

Administrator [Syncfusion]
Replied On February 27, 2005 09:24 PM UTC

To end the edit on the binder, try calling gridAdDrills.Binder.EndEdit().

Daniel Byers
Replied On February 28, 2005 02:32 AM UTC

Thanks, Clay. You da man!


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon