Object Reference > True DBGrid Properties > EditActive Property |
EditActive Property
Returns the status or enters/exits the cell editor.
TDBGrid.EditActive= boolean
Read/Write at run time. Not available at design time.
If this property returns True, then the current cell is currently being edited by the user. If False, then no editing is in progress.
If the grid is not already in edit mode, setting EditActive to True will initiate editing on the current cell. The caret will be positioned at the end of the cell and the ColEdit event will be triggered.
If the grid is already in edit mode, setting EditActive to False will exit edit mode. If the cell has been modified, this will trigger the following events: BeforeColUpdate, AfterColUpdate, and AfterColEdit.
Note
To cancel editing completely, set the CurrentCellModified property to False, then set EditActive to False.
The EditActive property does not correspond to the pencil in the RecordSelector column. The pencil reflects the state of the grid's DataChanged property.