DatePicker.DisplayDate Property
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets or sets the date to display.
public:
property DateTime DisplayDate { DateTime get(); void set(DateTime value); };
public DateTime DisplayDate { get; set; }
member this.DisplayDate : DateTime with get, set
Public Property DisplayDate As DateTime
The date to display. The default is Today.
The specified date is not in the range defined by DisplayDateStart. and DisplayDateEnd.
The following example creates a DatePicker that is initialized with its calendar open and displaying July 7, 2009.
<DatePicker IsDropDownOpen="True"
IsTodayHighlighted="False"
DisplayDate="7/7/09"/>
This property affects the Calendar of the DatePicker. For more information, see the Calendar.DisplayDate property.
Item | Value |
---|---|
Identifier field | DisplayDateProperty |
Metadata properties set to true |
BindsTwoWayByDefault |
This property allows the developer to specify a date to display if SelectedDate is null
.
<DatePicker DisplayDate="dateTimeString"/>
dateTimeString A date that is in one of the formats that are listed in the DateTime XAML Syntax topic.
Produto | Versões |
---|---|
.NET Framework | 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
Windows Desktop | 3.0, 3.1, 5, 6, 7, 8, 9, 10 |
Comentários do .NET
O .NET é um projeto código aberto. Selecione um link para fornecer comentários: