Articles in this section
Category / Section

How to access the value of hidden and visible columns of a record in WinForms GridGroupingControl?

1 min read

Access value of hidden and visible columns

Column value of a particular row can be accessed by using the gridGroupingControl1.Table.CurrentRecord. The DataRowView class can be used to get the data from the record. Refer to the following code example.

C#

private void gridGroupingControl1_CurrentRecordContextChange(object sender, Syncfusion.Grouping.CurrentRecordContextChangeEventArgs e)
{
   if(e.Action == CurrentRecordAction.EnterRecordComplete)
   {
      //Accesses Current record.
      Record rec = this.gridGroupingControl1.Table.CurrentRecord;
      Console.WriteLine(rec);
   }
} 

VB

Private Sub gridGroupingControl1_CurrentRecordContextChange(ByVal sender As Object, ByVal e As Syncfusion.Grouping.CurrentRecordContextChangeEventArgs)
   If e.Action = CurrentRecordAction.EnterRecordComplete Then
      'Accesses Current record.
      Dim rec As Record = Me.gridGroupingControl1.Table.CurrentRecord
      Console.WriteLine(rec)
   End If
End Sub

The following screenshots display accessing the value of a column.Show the hidden and visible column value

Samples:

C#: ColumnsValue-C#

VB: ColumnsValue-VB

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Please sign in to leave a comment
Access denied
Access denied