piDogDataView.DataView.CellDidEdit

Scope: Public
Event CellDidEdit(row as integer, column as integer, Action as DataView.EditorActions, editvalue as String, byref value as Variant, byref AllowMoveFocus as Boolean, byref EndEditing as boolean) As Boolean
Called when a cell has been edited by the user.
Return true to reject the edit.

EditValue is the text the user entered in the cell editor.

Set value to a variant value to interpret the edited value.

Action is one of

EditActionEnter = 0
EditActionTab = 1
EditActionLostFocus = 2
EditActionCancel = 3

AllowMoveFocus can be set to false to prevent focus from moving away from the cell editor


Example:

//prevents the user from entering a non-number value

AllowMoveFocus=( value>0 )
if AllowMoveFocus=False then value="Not a valid number"
Return not AllowMoveFocus