This topic describes the process of choosing and applying the different techniques on how you can provide data access in a List View using the Model Editor. Note that choosing the correct technique may be critical to achieving your XAF application's best performance.
The default mode in WinForms and ASP.NET applications is Client Mode, which is appropriate in most cases. The DataView, Server and InstantFeedback modes are intended to improve List View performance, but in different areas. In Mobile applications, only the Server mode is supported.
In the Model Editor, the IModelListView.DataAccessMode property of the Views | <ListView> node specifies how the displayed object collection is accessed. Available values - Client, Server, InstantFeedback and DataView are contained in the CollectionSourceDataAccessMode enumeration.
Modes that are not compatible with the current List Editor (specified using the IModelListView.EditorType property) are hidden from the combo box. If you use a custom List Editor, you can specify supported modes using the DataAccessModeHelper.RegisterEditorSupportedModes static method. You can call this method from any code that is executed at design time prior to loading the Model Editor (e.g., from the module's constructor). Pass the List Editor type and the list of it's supported modes to this method. By default, all modes are available for a custom List Editor.
You can change the data access mode globally for all List Views (except for the autogenerated nested List Views) using the IModelOptions.DataAccessMode property of the Options node. All manually created List Views, including nested List Views, have the same IModelListView.DataAccessMode property value as the global IModelOptions.DataAccessMode option.
To display a non-persistent property in the Server, InstantFeedback or Data View mode, apply the PersistentAliasAttribute or CalculatedAttribute attribute to this property declaration. Note that some operations, such as filtering, sorting and grouping, do not work with non-persistent properties in the InstantFeedback and Server modes, and to prevent these operations from execution for non-persistent properties, set the ColumnsListEditor.PreventServerSideOperationsForNonPersistentMembers to true.