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

Parent Row

Thread ID:

Created:

Updated:

Platform:

Replies:

19963 Oct 7,2004 12:17 AM Oct 7,2004 05:50 AM Windows Forms 4
loading
Tags: Grouping
Administrator [Syncfusion]
Asked On October 7, 2004 12:17 AM

1) May i know how to detect whether the parent row of the gridgroupingcontrol is being selected?? 2)How do u retrieve data from the parent row?

Administrator [Syncfusion]
Replied On October 7, 2004 01:00 AM

Hi Peggun, when a new record is selected a CurrentRecordContextChange event is raised. You can check this event to know which record is active. But since you are mentionioning "parent row"... If you are inside a nested table and a record is selected inside the nested table you can get a reference to the parent record with Record parentRecordOfNestedElement = element.ParentChildTable.ParentNestedTable.ParentRecord; Stefan

Administrator [Syncfusion]
Replied On October 7, 2004 01:53 AM

Does the parent row have any event for itself ? can I handle events by just selecting the parent row, instead of selecting the child row ?

Administrator [Syncfusion]
Replied On October 7, 2004 03:48 AM

basically i have a gridgroup control with one of the column set as group. how do i capture the data of the parent row in the gridgroup without expanding the group? reason for obtaining this data is to enable me to delete the whole group by accessing this parent row.

Administrator [Syncfusion]
Replied On October 7, 2004 05:50 AM

Is the DataSource a flat DataTable, or is it DataTable that has a Relation defined making it an hierarchical datasource? Here is code that is hit when you click on a CaptionRow in a grouped gridGroupingControl with a flat datasource.
private void gridGroupingControl2_CurrentRecordContextChange(object sender, Syncfusion.Grouping.CurrentRecordContextChangeEventArgs e)
{
	if(e.Action == CurrentRecordAction.EnterRecordComplete
		&& e.Record != null
		&& e.Record is GridCaptionRow)
	{
		GridCaptionRow rec = e.Record as GridCaptionRow;
		Console.WriteLine(rec.ToString());
	}
}

CONFIRMATION

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.

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.

;