New to Telerik UI for WPFStart a free 30-day trial

Provides a way to choose a DataTemplate for the ViewMode based on the data object and the data-bound element.

Definition

Namespace:Telerik.Windows.Controls

Assembly:Telerik.Windows.Controls.ScheduleView.dll

Syntax:

C#
public class ViewModeContentTemplateSelector : DataTemplateSelector

Inheritance: objectViewModeContentTemplateSelector

Constructors

C#
public ViewModeContentTemplateSelector()

Properties

Gets or sets the content template of the AgendaViewMode.

C#
public DataTemplate AgendaViewModeButtonContentTemplate { get; set; }

Gets or sets the content template of the DayViewMode.

C#
public DataTemplate DayViewModeButtonContentTemplate { get; set; }

Gets or sets the content template of the MonthViewMode.

C#
public DataTemplate MonthViewModeButtonContentTemplate { get; set; }

Gets or sets the content template of the TimelineViewMode.

C#
public DataTemplate TimelineViewModeButtonContentTemplate { get; set; }

Gets or sets the content template of the WeekViewMode.

C#
public DataTemplate WeekViewModeButtonContentTemplate { get; set; }

Methods

When overridden in a derived class, returns a System.Windows.DataTemplate based on a custom logic.

C#
public override DataTemplate SelectTemplate(object item, DependencyObject container)
Parameters:itemobject

The data object for which to select the template.

containerDependencyObject

The data-bound object.

Returns:

DataTemplate

Returns a custom DataTemplate or the default.