Skip to content

Calendar View

The Calendar gives developers a powerful yet practical way to manipulate dates within their apps.

CalendarView

Properties

CurrentYear - int

Gets or sets the current year. Default value is DateTime.Now.Year.

CurrentMonth - int

Gets or sets the current month. Default value is DateTime.Now.Month.

MaximumDate - DateTime

Gets or sets the maximum date. Default value is DateTime.MaxValue.

MinimumDate - DateTime

Gets or sets the minimum date. Default value is DateTime.MinValue.

HeaderTextColor - Color

Gets or sets the header text color. Default value is White.

SeparatorColor - Color

Gets or sets the color of the separator. Default value is LightGray.

UnavailableDateColor - Color

Gets or sets the color of the unavailable date. Default value is LightGray.

AvailableDateColor - Color

Gets or sets the color of the available date. Default value is White.

DateColor - Color

Gets or sets the color of the date. Default value is DarkGray.

SelectedDateColor - Color

Gets or sets the color of the selected date. Default value is MediumBlue.

DateTextColor - Color

Gets or sets the color of the date text. Default value is DarkGray.

SelectedDateTextColor - Color

Gets or sets the color of the selected date text. Default value is White.

DateBackgroundColor - Color

Gets or sets the color of the date background. Default value is DarkGray.

SelectionType - CalendarSelectionType

Gets or sets the type of the selection. Default value is Single. The following settings are available:

public enum CalendarSelectionType {
        Single,
        Span,
        Multiple
    }

Single allows the user to select only single dates at a time from the calendar.

Single

Span lets the user choose a contiguous range of dates.

Span

Multiple allows the user to select multiple spans of discontiguous dates.

Multiple

Example Usage

Xaml

<aurora:CalendarView x:Name="calendar" Margin="8" DateColor="Gray" SelectedDateColor="Blue" SeparatorColor="Black" />

C#

var calendar = new Aurora.Controls.CalendarView
    {
        MaximumDate = DateTime.Now.AddDays(23),
        BackgroundColor = Color.White,
        DateColor = Color.Black,
        SeparatorColor = Color.Gray
    };