TimePicker.ClockIdentifier Property
Definition
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 clock system to use.
public:
property Platform::String ^ ClockIdentifier { Platform::String ^ get(); void set(Platform::String ^ value); };
winrt::hstring ClockIdentifier();
void ClockIdentifier(winrt::hstring value);
public string ClockIdentifier { get; set; }
var string = timePicker.clockIdentifier;
timePicker.clockIdentifier = string;
Public Property ClockIdentifier As String
<TimePicker ClockIdentifier="12HourClock"/>
-or-
<TimePicker ClockIdentifier="24HourClock"/>
Property Value
The name of the clock system to use. See Remarks.
Examples
This example shows time pickers using both 12-hour and 24-hour clocks.
<TimePicker Header="12HourClock" SelectedTime="14:30"/>
<TimePicker Header="24HourClock" SelectedTime="14:30" ClockIdentifier="24HourClock"/>
Remarks
The type of the property is String, but you must use values that correspond to the static string properties of Windows.Globalization.ClockIdentifiers. These are: TwelveHour (the string "12HourClock")and TwentyFourHour (the string "24HourClock"). "12HourClock" is the default value.