Back to Devexpress

DXCalendar.YearCellTemplate Property

maui-devexpress-dot-maui-dot-editors-dot-dxcalendar-e8aebc10.md

latest1.5 KB
Original Source

DXCalendar.YearCellTemplate Property

Gets or sets a data template used to render years. This is a bindable property.

Namespace : DevExpress.Maui.Editors

Assembly : DevExpress.Maui.Editors.dll

NuGet Package : DevExpress.Maui.Editors

Declaration

csharp
public DataTemplate YearCellTemplate { get; set; }

Property Value

TypeDescription
DataTemplate

The template.

|

Remarks

Click the year in the calendar header to switch the calendar to Year view.

The CalendarCellData class specifies the binding context for the YearCellTemplate. You can use CalendarCellData properties to implement the template.

xaml
<dxe:DXCalendar.YearCellTemplate>
    <DataTemplate>
        <Label Text="{Binding Date, StringFormat='{0:yyyy}'}" TextColor="Purple"
         FontSize="16" FontAttributes="Bold"/>
    </DataTemplate>
</dxe:DXCalendar.YearCellTemplate>

See Also

DXCalendar Class

DXCalendar Members

DevExpress.Maui.Editors Namespace