BaseView.PostEditor() Method

Saves the modified cell value to the data source. If the GridOptionsView.RowAutoHeight setting is disabled, the currently active cell editor remains opened.

Namespace: DevExpress.XtraGrid.Views.Base

Assembly: DevExpress.XtraGrid.v21.1.dll


public bool PostEditor()


Type Description

true if the value has been successfully saved to the data source; otherwise, false.



Detail pattern Views do not contain data and they are never displayed within XtraGrid. So, the PostEditor member must not be invoked for these Views. The PostEditor member can only be used with real Views that are displayed within the Grid Control. The real Views with which an end-user interacts at runtime can be accessed using the following methods.

The code sample below illustrates how to save the value of a CheckEdit to the data source.

RepositoryItemCheckEdit checkEdit = new RepositoryItemCheckEdit();
checkEdit.EditValueChanged += repositoryItemCheckEdit_EditValueChanged;
gridView1.Columns["Marked"].ColumnEdit = checkEdit;

private void repositoryItemCheckEdit_EditValueChanged(object sender, System.EventArgs e)

Note that a row that is being edited is not saved until focus moves to another grid row. Call the UpdateCurrentRow method to make sure the current row is saved.

private void repositoryItemCheckEdit_EditValueChanged(object sender, EventArgs e) {
    if(gridView.PostEditor()) {
See Also