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.

How to get a child table''s CurrentRecord/Element in a nested ggc?

Thread ID:

Created:

Updated:

Platform:

Replies:

61848 Jun 4,2007 02:59 AM Jun 4,2007 09:36 PM Windows Forms 3
loading
Tags: GridControl
Ken Xu
Asked On June 4, 2007 02:59 AM

Hello,

As we known,a ggc binds a datasource like this:

ggc.DataSource = ds.Tables[n];

If I focus a child cell, and I found I can't get the CurrentRecord when I set a breakpoint and track the value:ggc.Table.CurrentRecord,it's equal to null.

Please help me!

Ken Xu
Replied On June 4, 2007 03:37 AM

Excuse me,
I have find a way to do that, but if you have a more official way , I will appreciate.

haneefm [Syncfusion]
Replied On June 4, 2007 05:36 PM

Hi Ken,

You can handle the TableControlCellClick event and get the CurrentRecord using the e.TableControl.Table.CurrentRecord property. Here is a code snippet

private void gridGroupingControl1_TableControlCellClick(object sender, GridTableControlCellClickEventArgs e)
{
Record rec = e.TableControl.Table.CurrentRecord;
}

If you wan to get current record on nested table, then use the GetTable("nestedTable").CurrentRecord property. Below is a code.

Record rec = this.grid.GetTable("nestedTableName").CurrentRecord;

Best regards,
Haneef

Ken Xu
Replied On June 4, 2007 09:36 PM

Wah~
We use the same code to get it~
Thank you,Haneef~

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.

;