DisplayDateStart Property

Calendar.DisplayDateStart Property


Gets or sets the first date that is available in the calendar.

Namespace:   System.Windows.Controls
Assembly:  PresentationFramework (in PresentationFramework.dll)

public Nullable<DateTime> DisplayDateStart { get; set; }

Property Value

Type: System.Nullable<DateTime>

The first date that is available in the calendar. The default is null.

You can restrict the range of a Calendar by setting the DisplayDateStart and DisplayDateEnd properties. A user cannot scroll to or select dates outside of this range. If you set the SelectedDate property to a date that is before DisplayDateStart, DisplayDateStart is set to the same value as SelectedDate.

<Calendar DisplayDateStart="dateTimeString"/>


A date that is in one of the formats that are listed in the DateTime XAML Syntax topic.

The following code sets up a Calendar with a particular range of displayable dates, and sets the currently selected and displayed date.

.NET Framework
Available since 4.0
Available since 2.0
Return to top
© 2015 Microsoft