Skip to main content

Flyout.ContentTemplateSelector Property

Gets or sets the DataTemplateSelector descendant that provides a way to select a particular data template used to render the content of the Flyout.

Namespace: DevExpress.Xpf.WindowsUI

Assembly: DevExpress.Xpf.Controls.v24.1.dll

NuGet Package: DevExpress.Wpf.Controls

Declaration

public DataTemplateSelector ContentTemplateSelector { get; set; }

Property Value

Type Description
DataTemplateSelector

A DataTemplateSelector descendant that provides the way to select a particular data template used to render the content of the Flyout.

Remarks

The ContentTemplateSelector property supports the MVVM design pattern. You can declare several data templates and apply one of them to render the content of the Flyout, based on your own logic. To implement this approach, first create the System.Windows.Controls.DataTemplateSelector descendant and override the DataTemplateSelector.SelectTemplate method to realize the template selection logic. Then, assign an instance of this object to the ContentTemplateSelector property and declare your data templates. The data templates can be defined in a resource dictionary.

To specify the content for the Flyout, use the Flyout.Content property.

See Also