When you use the VerticalGrid in custom binding mode, provide the extension with data manually upon each request. The VerticalGrid sends requests to the server using callbacks (see Using Callbacks). Each callback type should be associated with a handling Action in a Controller. You can define the callback routing logic by using specific properties exposed by the VerticalGrid. This topic provides information about the available callback routing properties of the VerticalGrid, and specifies which particular Actions should be handled in custom binding mode.
Callback Routing Properties
In general, the VerticalGrid has the following properties that allow you to define callback routing logic for different actions. The table below describes which properties and corresponding Actions relate to the custom binding implementation of the VerticalGrid.
The VerticalGrid does not automatically update (re-render) itself after this custom data callback, so it is not necessary to provide the extension with data during callback processing.
Handling the specified Action is not required for implementing the VerticalGrid's custom data binding. No specific custom binding parameter is automatically passed to the Action.
Action Types and Parameters that are Specific to Custom Binding
The VerticalGridSettings.CustomBindingRouteValuesCollection property allows you to assign particular handling Actions for three data operations – paging, sorting and filtering — which are specifically exposed to be handled in a custom manner to implement the custom data binding of the VerticalGrid. These operations are identified by the values of the VerticalGridOperationType enumeration. The table below lists the available data operation types, and provides additional information on how to assign and declare Actions that handle these operations.
An operation of this type is initiated if the paging-related state of the VerticalGrid is changed. For instance, an end-user moves to another VerticalGrid page (by clicking a pager navigation button or page number button) or changes the VerticalGrid's page size (using the pager's page size combo box).
An operation of this type is initiated if the sorting-related state of the VerticalGrid is changed. For instance, an end-user sorts a row by clicking its Row Header.
Note that a regular click on a row header clears the sort settings on other rows. To preserve the existing sort settings of other rows, an end-user can hold the SHIFT key down while clicking. This can be useful when sorting against multiple rows.
Represents the current state of the applied filter (contains the filter expression and the affected row/rows).
Note: When implementing the VerticalGrid's custom data binding, the DevExpressEditorsBinder must be used instead of the default model binder to correctly transfer values from DevExpress editors back to the corresponding data model fields. See the Binding to Model section in the Binding Data Editors to Data topic for more details on how to specify the DevExpressEditorsBinder as a model binder.