YearFormat YearFormat YearFormat YearFormat YearFormat Enum


Specifies the intended format for the year in a DateTimeFormatter object.

public : enum class YearFormat
enum class winrt::Windows::Globalization::DateTimeFormatting::YearFormat : int32_t
public enum YearFormat
Public Enum YearFormat
var value = Windows.Globalization.DateTimeFormatting.YearFormat.abbreviated;

Windows 10 requirements

Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)


Abbreviated Abbreviated Abbreviated Abbreviated Abbreviated 2

Display an abbreviated version of the year (for example, "11" for Gregorian 2011).

Default Default Default Default Default 1

Display the year in the most natural way. It may be abbreviated or full depending on the context, such as the language or calendar that is being used.

Full Full Full Full Full 3

Display the year in its entirety (for example, "2011" for Gregorian 2011).

None None None None None 0

Do not display the year.