Calendar Constructors
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.
Overloads
Calendar() |
Creates a Calendar object and initializes it to the current DateTime. |
Calendar(IIterable<String>) |
Creates a Calendar object that is initialized with a language list. |
Calendar(IIterable<String>, String, String) |
Creates a Calendar object that is initialized with a language list, calendar, and clock. |
Calendar(IIterable<String>, String, String, String) |
Creates a Calendar object that is initialized with a language list, calendar, clock, and time zone. |
Calendar()
public:
Calendar();
Calendar();
public Calendar();
function Calendar()
Public Sub New ()
See also
- Calendar(IIterable<String>, String, String)
- Calendar, date, and time controls
- Calendar sample
- Date and time formatting sample
Applies to
Calendar(IIterable<String>)
public:
Calendar(IIterable<Platform::String ^> ^ languages);
Calendar(IIterable<winrt::hstring> const& languages);
public Calendar(IEnumerable<string> languages);
function Calendar(languages)
Public Sub New (languages As IEnumerable(Of String))
Parameters
The list of language identifiers, in priority order, that represents the choice of languages. These are used for resolving patterns to strings.
Remarks
Language tags support the Unicode extensions "ca-" and "nu-". (See Unicode Key/Type Definitions.) Note that these extensions can affect the calendar used by Calendar objects.
See also
- Calendar(IIterable<String>, String, String)
- Unicode Key/Type Definitions
- Calendar, date, and time controls
- Calendar sample
- Date and time formatting sample
Applies to
Calendar(IIterable<String>, String, String)
public:
Calendar(IIterable<Platform::String ^> ^ languages, Platform::String ^ calendar, Platform::String ^ clock);
Calendar(IIterable<winrt::hstring> const& languages, winrt::hstring const& calendar, winrt::hstring const& clock);
public Calendar(IEnumerable<string> languages, string calendar, string clock);
function Calendar(languages, calendar, clock)
Public Sub New (languages As IEnumerable(Of String), calendar As String, clock As String)
Parameters
The list of language identifiers, in priority order, representing the choice of languages. These are used for resolving patterns to strings. See Remarks for Calendar.
- calendar
-
String
Platform::String
winrt::hstring
The calendar identifier to use.
- clock
-
String
Platform::String
winrt::hstring
The clock identifier to use.
See also
- Unicode Key/Type Definitions
- Calendar, date, and time controls
- Calendar sample
- Date and time formatting sample
Applies to
Calendar(IIterable<String>, String, String, String)
public:
Calendar(IIterable<Platform::String ^> ^ languages, Platform::String ^ calendar, Platform::String ^ clock, Platform::String ^ timeZoneId);
Calendar(IIterable<winrt::hstring> const& languages, winrt::hstring const& calendar, winrt::hstring const& clock, winrt::hstring const& timeZoneId);
public Calendar(IEnumerable<string> languages, string calendar, string clock, string timeZoneId);
function Calendar(languages, calendar, clock, timeZoneId)
Public Sub New (languages As IEnumerable(Of String), calendar As String, clock As String, timeZoneId As String)
Parameters
The list of language identifiers, in priority order, representing the choice of languages. These are used for resolving patterns to strings. See Remarks for Calendar.
- calendar
-
String
Platform::String
winrt::hstring
The calendar identifier to use.
- clock
-
String
Platform::String
winrt::hstring
The clock identifier to use.
- timeZoneId
-
String
Platform::String
winrt::hstring
An identifier from the IANA Time Zone Database which identifies the time zone that should be used (for example, "America/Los_Angeles" for Pacific Time).
See also
- Calendar(IIterable<String>)
- Calendar(IIterable<String>, String, String)
- Unicode Key/Type Definitions