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. Image for the cookie policy date

How do i change the value of a particular cell when using grid grouping?

Hi.. It seems that i have problems trying to change the value of a particular cell when i''''m using grip grouping control. I''''m very new to gripgrouping and i''''m not even sure how to get the data of a particular row of a particular column. (cell) Below are my codes. Dim intRow As Integer = ggcOrderProfileTestResults.TableModel.CurrentCellInfo.RowIndex() Dim strNA As String = ggcOrderProfileTestResults.Table.CurrentRecord.GetData()("NumericAlpha") If ggcOrderProfileTestResults.TableModel.CurrentCellInfo.ColIndex = 3 Then frmGeneral.ShowDialog() ggcOrderProfileTestResults.Table.CurrentRecord.SetValue("NumericAlpha", frmGeneral.Key) End If Can some one help?? thx a million..

1 Reply

AD Administrator Syncfusion Team October 6, 2004 06:01 AM UTC

Exactly what is it that you want to do? Do you want to change the value of the currentcell from a dialog in a button handler? If so, here is a button handler that worked for me in a little sample.
    Dim r As New Random

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        Dim colIndexOfCol1 As Integer = Me.GridGroupingControl1.TableControl.Model.NameToColIndex("Col1") ''some columname
        Dim currentRow As Integer = Me.GridGroupingControl1.TableControl.CurrentCell.RowIndex
        Dim currentCol As Integer = Me.GridGroupingControl1.TableControl.CurrentCell.ColIndex
        If (currentCol = colIndexOfCol1) Then
            MessageBox.Show("test") ''some dialog
            Me.GridGroupingControl1.TableControl.Table.CurrentRecord.SetValue("Col1", r.Next(10000))
        End If
    End Sub

Loader.
Live Chat Icon For mobile
Up arrow icon