XafApplication.CreateListEditor(CollectionSourceBase, IModelListView) Method

Creates the List Editor which is specified in the appropriate Application Model node.

Namespace: DevExpress.ExpressApp

Assembly: DevExpress.ExpressApp.v18.2.dll

Declaration

public ListEditor CreateListEditor(
    CollectionSourceBase collectionSource,
    IModelListView modelListView
)
Public Function CreateListEditor(
    collectionSource As CollectionSourceBase,
    modelListView As IModelListView
) As ListEditor

Parameters

Type Name Description
CollectionSourceBase collectionSource

A CollectionSourceBase object representing the Collection Source of the List View which is displayed via the new ListEditor object.

IModelListView modelListView

An IModelListView object representing the Application Model node that defines the List View for which a List Editor is created.

Returns

Type Description
ListEditor

An appropriate List Editor.

Remarks

This method creates the List Editor of the type specified by the IModelListView.EditorType property of the Views | <ListView> node which is passed as the info parameter. If the List View cannot be created, an exception is raised.

A List Editor can implement the IComplexListEditor and/or IProtectedContentEditor interface. If the IComplexListEditor interface is implemented, its Setup method is called. If the IProtectedContentEditor interface is implemented, its ProtectedContentText property is set to the Application node's IModelApplication.ProtectedContentText property value.

You may need to use this method if a custom Property Editor displays its value via a List View. In this instance, use the List View's constructor with the listEditor parameter (see XafApplication.CreateListView).

See Also