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

Resume a specific value from a row, any cell is pressed

Thread ID:





130729 May 29,2017 05:47 PM UTC May 30,2017 12:38 PM UTC WinForms 1
Tags: GridDataBoundGrid(Classic)
Asked On May 29, 2017 05:47 PM UTC

how can this "dataGridView1.CurrentRow.Cells["ID"].Value" be converted for GridDataBound  to have the same effect.

Arulpriya Ramalingam [Syncfusion]
Replied On May 30, 2017 12:38 PM UTC

Hi Nino, 

Thanks for using Syncfusion products. 

We could able to understand your scenario. In GridDataBoundGrid, the cell value of a particular cell can be retrieved from current record value using GetRecordStateAtRowIndex and GetValue methods. The GetRecordStateAtRowIndex method can be used to get the current record and GetValue method can be used to get the particular cell value. Please make use of the provided code sample and KB link, 

Code snippet 
//Event Subscription 
gridDataBoundGrid1.CurrentCellControlDoubleClick += GridDataBoundGrid1_CurrentCellControlDoubleClick; 
//Event Customization 
private void GridDataBoundGrid1_CurrentCellControlDoubleClick(object sender, ControlEventArgs e) 
    if (gridDataBoundGrid1.CurrentCell.ColIndex == 2) 
        int rowIndex = gridDataBoundGrid1.CurrentCell.RowIndex; 
        //To get the current record 
        GridBoundRecordState record = this.gridDataBoundGrid1.Binder.GetRecordStateAtRowIndex(rowIndex); 
        foreach (GridBoundColumn column in this.gridDataBoundGrid1.Binder.InternalColumns) 
            if (column.MappingName == "Description") 
                //To get the particular cell value 
                string value = column.PropertyDescriptor.GetValue(record.Table[record.Position]).ToString(); 



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

or the page will be automatically redirected to 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