In FlexGrid, edit mode can be invoked at runtime using mouse click or even keyboard. To determine programmatically whether the grid is in edit mode, you can read the value of ActiveEditor property. If the grid is in edit mode, the property returns a reference to the control that is being used as editor such as TextBox or ComboBox. However, if the grid is not in edit mode, the property returns null.
To put the grid in edit mode programmatically, you can use the StartEditing method and to finish editing, you can call the FinishEditing method.
In addition, FlexGrid fires various events to facilitate better control on the editing process. Below table lists the sequence of events which are fired by the grid during the editing process.
Event Name | Description |
---|---|
BeginningEdit | The event occurs when the editing process in a cell is about to start. |
CellEditEnded | The event occurs after the editing process of a cell is committed. |
CellEditEnding | The event occurs before the editing process in a cell is committed. |
PrepareCellForEdit | The event occurs before an editor cell becomes active and it is created. |