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

CurrentCellEditingComplete

Hi, I want to know when a user validate a cell the first time with a text!="". example: a cell is empty and I fill it with 'Hello World' I do not see which event to use. CurrentCellEditingComplete does not inform you of the old value (was it ""?), neither CurrentCellChanged... The only event that could fit is CurrentCellValidateString but it is reached each time you enter a key, not after validation (enter...) Is there an easy way to do it? Sebastien

1 Reply

CB Clay Burch Syncfusion Team September 13, 2002 12:57 PM UTC

> Hi, > > I want to know when a user validate a cell the first time with a text!="". > example: a cell is empty and I fill it with 'Hello World' > I do not see which event to use. > CurrentCellEditingComplete does not inform you of the old value (was it ""?), neither CurrentCellChanged... > The only event that could fit is CurrentCellValidateString but it is reached each time you enter a key, not after validation (enter...) > Is there an easy way to do it? > > Sebastien How about the CurrentCellValidating event? You can get the new text from the ControlText property of the CurrentCell.Renderer, and you can get the old text just by indexing the grid object with the currentcell row and col.
Private Sub GridControl1_CurrentCellValidating(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles GridControl1.CurrentCellValidating
	Dim cc As GridCurrentCell = GridControl1.CurrentCell
	Console.WriteLine(cc.Renderer.ControlText + "**" + Me.GridControl1(cc.RowIndex, cc.ColIndex).Text)
    End Sub

Loader.
Up arrow icon