ViewController.TargetViewType Property

Specifies the type of the View, for which a View Controller is intended.

Namespace: DevExpress.ExpressApp

Assembly: DevExpress.ExpressApp.v18.1.dll

Declaration

public ViewType TargetViewType { get; set; }
Public Property TargetViewType As ViewType

Property Value

Type Description
ViewType

A ViewType enumeration value identifying a View type.

View Controllers can be activated for both List and Detail Views. You can use the TargetViewType property to provide View Controller activation within the List, Detail, or any type of View.

Note

The TargetViewType property affects only ViewController's activation. Controller.FrameAssigned and other events that are irrelevant to the view type always fire.

Alternatively, you can implement the generic ViewController<ViewType> Controller instead of the ViewController and specify the View's type, for which this Controller is intended, in the ViewType generic parameter. In this case, you do not need to perform an additional cast when you access the View.

See Also