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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Finding a Record from DataRow

Thread ID:





81188 May 15,2009 12:16 PM UTC May 18,2009 02:14 PM UTC WinForms 1
Tags: GridControl
Administrator [Syncfusion]
Asked On May 15, 2009 12:16 PM UTC

I am using a GridGroupingControl. I use a DataTable as the DataSource for this grid. Is there a direct way of finding the Syncfusion Record from the DataRow of that DataTable?

Rajadurai C [Syncfusion]
Replied On May 18, 2009 02:14 PM UTC

Hi Phani,

Thanks for your interest in Syncfusion products.

Please refer to the following code showing how to get the record value from the underlying data handled in QueryCellStyleInfo event.

void gridGroupingControl1_QueryCellStyleInfo(object sender, Syncfusion.Windows.Forms.Grid.Grouping.GridTableCellStyleInfoEventArgs e)
GridRecord record = e.TableCellIdentity.DisplayElement.GetRecord() as GridRecord;
if (record != null)
//to get the raw dataobject, ie the DataRowView from a DataTable datasource
//you can use
object data = record.GetData();
DataRowView drv = data as DataRowView;
if (drv != null)
Console.WriteLine("field0={0} field1={1}", drv[0], drv[1]);



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