Skip to main content
Tab

GridViewBatchEditSettings.KeepChangesOnCallbacks Property

Specifies whether the grid keeps changes on callbacks in batch edit mode.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v24.2.dll

Declaration

[DefaultValue(DefaultBoolean.Default)]
public DefaultBoolean KeepChangesOnCallbacks { get; set; }

Property Value

Type Default Description
DefaultBoolean Default

True to keep changes on callbacks.
False to reset changes on callbacks.
Default to determine the control’s behavior based on the DataControlBatchEditKeepChangesOnCallbacksDefaultValue property value.

Available values:

Name Description Return Value
True

The value is true.

0

False

The value is false.

1

Default

The value is specified by a global option or a higher-level object.

2

Property Paths

You can access this nested property as listed below:

Object Type Path to KeepChangesOnCallbacks
ASPxGridViewEditingSettings
.BatchEditSettings .KeepChangesOnCallbacks

Remarks

In batch edit mode, the grid allows a user to edit batches of grid data on multiple pages and send them to the server in a single request. To support this functionality, the grid keeps changes on callbacks when a user interacts with unsaved modified data (for instance, when a user navigates to another page within the grid or sorts data).

The enabled KeepChangesOnCallbacks property also allows the grid to display the Preview Changes button. When a user clicks this button, the grid shows only modified rows from all grid pages.

ASPxGridView.BatchEditMode - PreviewChangesButton ASPxGridView.BatchEditMode - HideChangesButton

When the KeepChangesOnCallbacks property is disabled, the grid behaves as follows:

  • Does not display the Preview Changes button.

  • Shows the Confirmation dialog box on callbacks (the ShowConfirmOnLosingChanges property) to confirm user interactions with unsaved modified data.

    ASPxGridView.BatchEditMode - ConfirmationMessage

    <dx:ASPxGridView ID="ASPxGridView1" runat="server" KeyFieldName="ProductID">
      <%--...--%>
      <SettingsEditing Mode="Batch">
          <BatchEditSettings EditMode="Cell" KeepChangesOnCallbacks="False"/>
      </SettingsEditing>
    </dx:ASPxGridView>
    

If the KeepChangesOnCallbacks property is set to Default, the control’s behavior is based on the DataControlBatchEditKeepChangesOnCallbacksDefaultValue property value.

ASPxWebControl.BackwardCompatibility.DataControlBatchEditKeepChangesOnCallbacksDefaultValue = false;

Run Demo: ASPxGridView - Batch Editing and Updating

See Also