LCTYPE Constants (National Language Support)

NLS specifies a particular piece of locale information using an LCTYPE constant. The names of all LCTYPE constants begin with "LOCALE". Names of constants that represent integer values begin with "LOCALE_I". All values for these constants are null-terminated Unicode strings. Maximum string lengths specified in this topic include the terminating null character. If no maximum length is indicated for a constant, its values can vary in length.

The functions GetLocaleInfo, GetLocaleInfoEx, and SetLocaleInfo use the LCTYPE constants to identify locale information. The information can be retrieved by GetLocaleInfo (Windows 98/Me, Windows NT 4.0 and later) or GetLocaleInfoEx (Windows Vista and later) either as strings (default) or as integers. An integer return is specified by using the binary OR operator to combine the particular constant with LOCALE_RETURN_NUMBER.

This topic includes:

  • Combining Constants
  • Locale Identifier Constants
  • Locale Name Constants
  • Constants Used by Both SetLocaleInfo and GetLocaleInfo/GetLocaleInfoEx
  • Constants Used by GetLocaleInfo/GetLocaleInfoEx Only
  • Closely Related LCTYPE Constants

Combining Constants

The following LCTYPE constants can be combined with other LCTYPE constants. The remainder of the LCTYPE constants are mutually exclusive, and cannot be combined with one another using the binary OR operator.

  • LOCALE_NOUSEROVERRIDE
    No user override. This constant can be combined with any other LCTYPE constant by using the binary OR operator. In several functions, for example, GetLocaleInfo and GetLocaleInfoEx, this constant causes the function to bypass any user override and use the system default value for any other LCTYPE constant specified in the function call. The information is retrieved from the locale database, even if the identifier indicates the current locale and the user has changed some of the values using the Control Panel, or if an application has changed these values by using SetLocaleInfo. If this constant is not specified, any values that the user has configured from the Control Panel or that an application has configured using SetLocaleInfo take precedence over the database settings for the current system default locale. Note: Since LOCALE_NOUSEROVERRIDE disables user preferences, its use is discouraged.
  • LOCALE_RETURN_NUMBER
    Windows 98/Me, Windows NT 4.0 and later: A number return. This constant causes GetLocaleInfo or GetLocaleInfoEx to return a value as a number instead of as a string. The buffer that receives the value must be at least the length of a DWORD value. By using the binary OR operator, this constant can be combined with any other LCTYPE constant having a name that begins with LOCALE_I.
  • LOCALE_USE_CP_ACP
    Windows 98/Me, Windows 2000 and later: System ANSI code page (ACP) instead of the locale code page used for string translation. This constant is only relevant for the ANSI versions GetLocaleInfoA and SetLocaleInfoA.

Locale Identifier Constants

The locale identifier constants are detailed in Locale Identifier Constants and Strings.

Locale Name Constants

The constants listed in the following table are used to specify a locale name. They are used by functions such as GetLocaleInfoEx.

Value Meaning
LOCALE_NAME_INVARIANT Invariant locale name.
LOCALE_NAME_SYSTEM_DEFAULT System default locale name.
LOCALE_NAME_USER_DEFAULT User default locale name.

LOCALE_NAME_MAX_LENGTH is a related constant. It represents the maximum length of the locale name. The maximum number of characters allowed for this string is 85, including a terminating null character.

Note: Your application must use the constant for the maximum locale name length, instead of hard-coding the value "85".

Constants Used by Both SetLocaleInfo and GetLocaleInfo/GetLocaleInfoEx

SetLocaleInfo uses the following LCTYPE constants to set particular pieces of user locale information, and GetLocaleInfo or GetLocaleInfoEx uses these same constants to retrieve those pieces of information. These constants are mutually exclusive of one another and of the constants used by GetLocaleInfo or GetLocaleInfoEx only. They cannot be combined with one another. However, they can be combined with the combining constants using the binary OR operator. See Combining Constants.

  • LOCALE_ICALENDARTYPE
    Current calendar type. Possible values are defined in Calendar Identifiers. The calendar type can only represent a calendar that is available for the corresponding locale. To retrieve all calendars available for a locale, the application can use the following NLS functions:

  • LOCALE_ICURRDIGITS
    Number of fractional digits for the local monetary format. The maximum number of characters allowed for this string is two, including the values 0-9 and a terminating null character. For example, 200.00 has a value of 2 because there are two fractional digits, while 200 has a value of 0 because there are no fractional digits displayed.

  • LOCALE_ICURRENCY
    Position of the monetary symbol in the positive currency mode. The mode can be one of the following values.

    Value Meaning
    0 Prefix, no separation, for example $1.1
    1 Suffix, no separation, for example 1.1$
    2 Prefix, 1-character separation, for example $ 1.1
    3 Suffix, 1-character separation, for example 1.1 $
  • LOCALE_IDIGITS
    Number of fractional digits placed after the decimal separator. The maximum number of characters allowed for this string is two, including a terminating null character. For example, 2 for 5.00, 1 for 5.0.

  • LOCALE_IDIGITSUBSTITUTION
    Windows 2000 and later: Determines the shape of the digits. For example, Arabic, Thai, and Indic digits have classical shapes different from European digits. The specifier can be one of these values. For locales with LOCALE_SNATIVEDIGITS specified as values other than ASCII 0-9, this specifies whether preference should be given to those other digits for display purposes. For example, a value of 2 is chosen, then the digits specified by LOCALE_SNATIVEDIGITS field are always used. If a 1 is chosen, then the ASCII 0-9 digits are always used. If a 0 is chosen, then ASCII is used in some circumstances and those specified by LOCALE_SNATIVEDIGITS are used in others, depending on the context.

    Value Meaning
    0 Context-based substitution. Digits are displayed based on the previous text in the same output: that is, European digits follow Latin scripts, Arabic-Indic digits follow Arabic text, and other national digits follow text written in various other scripts. When there is no preceding text, the locale and the displayed reading order determine digit substitution, as shown in the following table.
    Locale Reading order Digits used
    Arabic Right-to-left Arabic-Indic
    Thai Left-to-right Thai digits
    All others Any No substitution is used.
    1 No substitution is used. This gives full Unicode compatibility.
    2 Native digit substitution. National shapes are displayed according to LOCALE_SNATIVEDIGITS.

  • LOCALE_IFIRSTDAYOFWEEK
    Specifier for the first day in a week. The specifier can be one of these values.

    Value Meaning
    0 LOCALE_SDAYNAME1 (Monday)
    1 LOCALE_SDAYNAME2 (Tuesday)
    2 LOCALE_SDAYNAME3 (Wednesday)
    3 LOCALE_SDAYNAME4 (Thursday)
    4 LOCALE_SDAYNAME5 (Friday)
    5 LOCALE_SDAYNAME6 (Saturday)
    6 LOCALE_SDAYNAME7 (Sunday)
  • LOCALE_IFIRSTWEEKOFYEAR
    Specifier for the first week of the year. The specifier can be one of these values.

    Value Meaning
    0 Week containing 1/1 is the first week of that year. Note that this can be a single day, if 1/1 falls on the last day of the week.
    1 First full week following 1/1 is the first week of that year.
    2 First week containing at least four days is the first week of that year.
  • LOCALE_ILZERO
    Specifier for leading zeros in decimal fields. The specifier can be one of the following values.

    Value Meaning
    0 No leading zeros before the decimal; for example, specify 0 for .987
    1 Leading zeros; for example, specify 1 for 0.987
  • LOCALE_IMEASURE
    System of measurement. The maximum number of characters allowed for this string is two, including a terminating null character. This value is 0 if the metric system (Systéme International d'Units, or S.I.) is used, and 1 if the U.S. system is used.

  • LOCALE_INEGCURR
    Negative currency mode. The mode can be one of the following values.

    Mode Format for a negative currency
    0 Left parenthesis, monetary symbol, number, right parenthesis.

    Example: ($1.1)

    1 Negative sign, monetary symbol, number. Example: -$1.1
    2 Monetary symbol, negative sign, number. Example: $-1.1
    3 Monetary symbol, number, negative sign. Example: $1.1-
    4 Left parenthesis, number, monetary symbol, right parenthesis. Example: (1.1$)
    5 Negative sign, number, monetary symbol. Example: -1.1$
    6 Number, negative sign, monetary symbol. Example: 1.1-$
    7 Number, monetary symbol, negative sign. Example: 1.1$-
    8 Negative sign, number, space, monetary symbol (like #5, but with a space before the monetary symbol). Example: -1.1 $
    9 Negative sign, monetary symbol, space, number (like #1, but with a space after the monetary symbol). Example: -$ 1.1
    10 Number, space, monetary symbol, negative sign (like #7, but with a space before the monetary symbol). Example: 1.1 $-
    11 Monetary symbol, space, number, negative sign (like #3, but with a space after the monetary symbol). Example: $ 1.1-
    12 Monetary symbol, space, negative sign, number (like #2, but with a space after the monetary symbol). Example: $ -1.1
    13 Number, negative sign, space, monetary symbol (like #6, but with a space before the monetary symbol). Example: 1.1- $
    14 Left parenthesis, monetary symbol, space, number, right

    parenthesis (like #0, but with a space after the monetary symbol). Example: ($ 1.1)

    15 Left parenthesis, number, space, monetary symbol, right parenthesis (like #4, but with a space before the monetary symbol). Example: (1.1 $)
  • LOCALE_INEGNUMBER
    Negative number mode, that is, the format for a negative number. The mode can be one of these values.

    Value Format
    0 Left parenthesis, number, right parenthesis. Example: (1.1)
    1 Negative sign, number. Example: -1.1
    2 Negative sign, space, number. Example: - 1.1
    3 Number, negative sign. Example: 1.1-
    4 Number, space, negative sign. Example: 1.1 -
  • LOCALE_IPAPERSIZE
    Windows 2000 and later: Default paper size associated with the locale. The specifier is typically one of the following values, although it can be set to any of the defined paper sizes that are understood by the spooler.

    Value Meaning
    1 US Letter
    5 US legal
    8 A3
    9 A4
  • LOCALE_ITIME
    Time format specification. The specification is one of the following values. It is preferred for your application to use the LOCALE_STIMEFORMAT constant instead of LOCALE_ITIME.

    Value Description
    0 AM / PM 12-hour format
    1 24-hour format
  • LOCALE_S1159
    String for the AM designator (first 12 hours of the day). The maximum number of characters allowed for this string, including a terminating null character, is different for different releases of Windows.

    Windows 95/98/Me, Windows NT 4/2000: nine including a terminating null character
    Windows XP: thirteen including a terminating null character for SetLocaleInfo; fifteen including a terminating null character for GetLocaleInfo
    Windows Server 2003 and later: fifteen including a terminating null character

  • LOCALE_S2359
    String for the PM designator (second 12 hours of the day). The maximum number of characters allowed for this string is different for different releases of Windows.

    Windows 95/98/Me, Windows NT 4/2000: nine including a terminating null character
    Windows XP: thirteen including a terminating null character for SetLocaleInfo; fifteen including a terminating null character for GetLocaleInfo1159
    Windows Server 2003 and later: fifteen including a terminating null character

  • LOCALE_SCURRENCY
    String used as the local monetary symbol. The maximum number of characters allowed for this string is six, including a terminating null character. For example, in the United States this symbol would be "$".

  • LOCALE_SDATE
    Character(s) for the date separator. The maximum number of characters allowed for this string is four, including a terminating null character.

    Windows Vista and later: This constant is obsolete. Do not use. Use LOCALE_SSHORTDATE instead. A custom locale might not have a single, uniform separator character. For example, a format like "12/31, 2006" is valid.

  • LOCALE_SDECIMAL
    Character(s) used as the decimal separator, for example, "." in "3.14" or "," in "3,14". The maximum number of characters allowed for this string is four, including a terminating null character.

  • LOCALE_SGROUPING
    Sizes for each group of digits to the left of the decimal. The maximum number of characters allowed for this string is ten, including a terminating null character. An explicit size is needed for each group, and sizes are separated by semicolons. If the last value is zero, the preceding value is repeated. For example, to group thousands, specify 3;0. Indic locales group the first thousand and then group by hundreds. For example, 12,34,56,789 is represented by 3;2;0.

    Further examples:

    Specification Resulting string
    3;0 3,000,000,000,000
    3;2;0 30,00,00,00,00,000
    3 3000000000,000
    3;2 30000000,00,000
  • LOCALE_SLIST
    Character(s) that are used to separate list items, for example, a comma is used in many locales. The maximum number of characters allowed for this string is four, including a terminating null character.

  • LOCALE_SLONGDATE
    Long date formatting string for the locale. The maximum number of characters allowed for this string is 80, including a terminating null character. The string can consist of a combination of day, month, and year format pictures defined in the Day, Month, Year, and Era Format Pictures table in National Language Support Constants and any string of characters enclosed in single quotes. Characters in single quotes remain as specified. For example, the Spanish (Spain) long date is "dddd, dd' de 'MMMM' de 'yyyy".

    Locales can define multiple long date formats. To get all of the long date formats for this locale, use EnumDateFormats, EnumDateFormatsEx, or EnumDateFormatsExEx.

  • LOCALE_SMONDECIMALSEP
    Character(s) used as the monetary decimal separator. The maximum number of characters allowed for this string is four, including a terminating null character. For example, if a monetary amount is displayed as "$3.40", just as "three dollars and forty cents" is displayed in the United States, then the monetary decimal separator is ".".

  • LOCALE_SMONGROUPING
    Sizes for each group of monetary digits to the left of the decimal. The maximum number of characters allowed for this string is ten, including a terminating null character. An explicit size is needed for each group, and sizes are separated by semicolons. If the last value is zero, the preceding value is repeated. For example, to group thousands, specify 3;0. Indic languages group the first thousand and then group by hundreds. For example 12,34,56,789 is represented by 3;2;0.

  • LOCALE_SMONTHOUSANDSEP
    Character(s) used as the monetary separator between groups of digits to the left of the decimal. The maximum number of characters allowed for this string is four, including a terminating null character. Typically, the groups represent thousands. However, depending on the value specified for LOCALE_SMONGROUPING, they can represent something else.

  • LOCALE_SNATIVEDIGITS
    Native equivalents to ASCII 0 through 9. The maximum number of characters allowed for this string is eleven, including a terminating null character. For example, Arabic uses "٠١٢٣٤٥ ٦٧٨٩". See also LOCALE_IDIGITSUBSTITUTION.

  • LOCALE_SNEGATIVESIGN
    String value for the negative sign, for example, "-" for the English (United States) locale. The maximum number of characters allowed for this string is five, including a terminating null character.

  • LOCALE_SPOSITIVESIGN
    String value for the positive sign, for example, "+" for the English (United States) locale. The maximum number of characters allowed for this string is five, including a terminating null character.

  • LOCALE_SSHORTDATE
    Short date formatting string for the locale. The maximum number of characters allowed for this string is 80, including a terminating null character. The string can consist of a combination of day, month, and year format pictures defined in Day, Month, Year, and Era Format Pictures table in National Language Support Constants. For example, M/d/yyyy indicates that September 3, 2004 would be written 9/3/2004.

    Locales can define multiple short date formats. To get all of the short date formats for this locale, use EnumDateFormats, EnumDateFormatsEx, or EnumDateFormatsExEx.

  • LOCALE_STHOUSAND
    Character(s) that are used to separate groups of digits to the left of the decimal. The maximum number of characters allowed for this string is four, including a terminating null character. Typically, these groups represent thousands. However, depending on the value specified for LOCALE_SGROUPING, they can represent something else.

  • LOCALE_STIME
    Character(s) for the time separator. The maximum number of characters allowed for this string is four, including a terminating null character.

    Windows Vista and later: This constant is obsolete. Do not use. Use LOCALE_STIMEFORMAT instead. A custom locale might not have a single, uniform separator character. For example, a format like "03:56'23" is valid.

  • LOCALE_STIMEFORMAT
    Time formatting strings for this locale. The maximum number of characters allowed for this string is 80, including a terminating null character. The string can consist of a combination of the hour, minute, and second format pictures defined in the Hour, Minute, and Second Format Pictures table in National Language Support Constants.

  • LOCALE_SYEARMONTH
    Windows 98/Me, Windows 2000 and later: The year/month formatting string for the locale. The maximum number of characters allowed for this string is 80, including a terminating null character. This string shows the proper format for a date string that contains only the year and the month, using format pictures as defined in Day, Month, Year, and Era Format Pictures table in National Language Support Constants.

Constants Used by GetLocaleInfo/GetLocaleInfoEx Only

GetLocaleInfo and GetLocaleInfoEx use the following LCTYPE constants to get certain pieces of locale information that SetLocaleInfo cannot set. These constants are mutually exclusive of one another and of the constants used by both SetLocaleInfo and GetLocaleInfo/GetLocaleInfoEx, and cannot be combined with one another. However, by using the binary OR operator, they can be combined with the combining constants.

  • LOCALE_FONTSIGNATURE
    Windows 95/98/Me, Windows NT 4.0 and later: A bit pattern that determines the relationship between the character coverage needed to support the locale and the font contents. Note that LOCALE_FONTSIGNATURE data takes a different form from all other locale information. All other locale information can be expressed in a string form or (where appropriate) as a number. LOCALE_FONTSIGNATURE is returned in a LOCALESIGNATURE structure.

  • LOCALE_ICENTURY
    Specifier for a 2-digit or 4-digit century for the short date only. The specifier can be one of the following values. It is preferred for your application to use the LOCALE_SSHORTDATE constant instead of LOCALE_ICENTURY.

    Value Meaning
    0 Abbreviated 2-digit century
    1 Full 4-digit century
  • LOCALE_ICOUNTRY
    Country/region code, based on international phone codes, also referred to as IBM country/region codes. The maximum number of characters allowed for this string is six, including a terminating null character.

  • LOCALE_IDATE
    Short date format-ordering specifier. The specifier must be one of the following values. No user-specified values are allowed. It is preferred for your application to use the LOCALE_SSHORTDATE constant instead of LOCALE_IDATE.

    Value Meaning
    0 Month-Day-Year
    1 Day-Month-Year
    2 Year-Month-Day
  • LOCALE_IDAYLZERO
    Specifier for leading zeros in day fields for the short date only. The maximum number of characters allowed for this string is two, including a terminating null character. The specifier can be one of the following values. It is preferred for your application to use the LOCALE_SSHORTDATE constant instead of LOCALE_IDAYLZERO.

    Value Meaning
    0 No leading zeros for days
    1 Leading zeros for days
  • LOCALE_IDEFAULTANSICODEPAGE
    The ANSI code page used by a locale for applications that do not support Unicode. The maximum number of characters allowed for this string is six, including a terminating null character. If no ANSI code page is available, only Unicode can be used for the locale. In this case, the value is CP_ACP (0). For a list of ANSI and other code pages, see Code Page Identifiers.

  • LOCALE_IDEFAULTCODEPAGE
    Original equipment manufacturer (OEM) code page associated with the country/region. The OEM code page is used for conversion from MS-DOS-based, text-mode applications.

    If the locale does not use an OEM code page, the value is CP_OEMCP (1). The maximum number of characters allowed for this string is six, including a terminating null character. For a list of OEM and other code pages, see Code Page Identifiers.

  • LOCALE_IDEFAULTCOUNTRY
    Obsolete. Do not use. This value was provided so that partially specified locales could be completed with default values. Partially specified locales are now deprecated.

  • LOCALE_IDEFAULTEBCDICCODEPAGE
    Windows 2000 and later: Default Extended Binary Coded Decimal Interchange Code (EBCDIC) code page associated with the locale. The maximum number of characters allowed for this string is six, including a terminating null character. For a list of EBCDIC and other code pages, see Code Page Identifiers.

  • LOCALE_IDEFAULTLANGUAGE
    Obsolete. Do not use. This value was provided so that partially specified locales could be completed with default values. Partially specified locales are now deprecated.

  • LOCALE_IDEFAULTMACCODEPAGE
    Default Macintosh code page associated with the locale. The maximum number of characters allowed for this string is six, including a terminating null character. If the locale does not use a Macintosh code page, the value is CP_MACCP (2). For a list of Macintosh (MAC) and other code pages, see Code Page Identifiers.

  • LOCALE_IGEOID
    A 32-bit signed number that uniquely identifies a geographical location. The application uses this constant to provide locale-specific services to customers. For example, it can be used as a key to access a database record that contains specific information about a country/region.

  • LOCALE_IINTLCURRDIGITS
    Number of fractional digits for the international monetary format. The maximum number of characters allowed for this string is three, including a terminating null character. For example, the number of fractional digits for the international monetary format of US Dollars is 2, as in $345.25.

  • LOCALE_ILANGUAGE
    Language identifier with a hexadecimal value. For example, English (United States) has the value 0409, which indicates 0x0409 hexadecimal, and is equivalent to 1033 decimal. The maximum number of characters allowed for this string is five, including a terminating null character.

    Windows Vista and later: Use of this constant can cause GetLocaleInfo to return an invalid locale identifier. It is recommended for your application to use the LOCALE_SNAME constant when calling this function.

  • LOCALE_ILDATE
    Long date format-ordering specifier. The specifier can be one of the following values. It is preferred for your application to use the LOCALE_SLONGDATE constant instead of LOCALE_ILDATE.

    Value Meaning
    0 Month-Day-Year
    1 Day-Month-Year
    2 Year-Month-Day
  • LOCALE_IMONLZERO
    Specifier for leading zeros in month fields for the short date only. The specifier can be one of the following values. It is preferred for your application to use the LOCALE_SSHORTDATE constant instead of LOCALE_IMONLZERO.

    Value Meaning
    0 No leading zeros for months
    1 Leading zeros for months
  • LOCALE_INEGSEPBYSPACE
    Separation of the negative sign in a monetary value. This value is 1 if the monetary symbol is separated by a space from the negative amount, 0 if it is not.

  • LOCALE_INEGSIGNPOSN
    Formatting index for the negative sign in currency values. The index can be one of the following values.

    Value Meaning
    0 Parentheses surround the amount and the monetary symbol.
    1 The sign precedes the number.
    2 The sign follows the number.
    3 The sign precedes the monetary symbol.
    4 The sign follows the monetary symbol.
  • LOCALE_INEGSYMPRECEDES
    Position of monetary symbol in a negative monetary value. This value is 1 if the monetary symbol precedes the negative amount, 0 if it follows it.

  • LOCALE_IOPTIONALCALENDAR
    An optional calendar type that is available for a locale. Possible values are defined in Calendar Identifiers. The calendar type can only represent an optional calendar that is available for the corresponding locale. To retrieve all optional calendars available for a locale, the application can use the following NLS functions:

  • LOCALE_IPOSSEPBYSPACE
    Separation of monetary symbol in a positive monetary value. This value is 1 if the monetary symbol is separated by a space from a positive amount, 0 if it is not.

  • LOCALE_IPOSSIGNPOSN
    Formatting index for positive values. The index uses the same values as LOCALE_INEGSIGNPOSN, except that it does not use the zero index.

  • LOCALE_IPOSSYMPRECEDES
    Position of monetary symbol in a positive monetary value. This value is 1 if the monetary symbol precedes the positive amount, zero if it follows it.

  • LOCALE_ITIMEMARKPOSN
    Specifier indicating whether the time marker string (AM or PM) precedes or follows the time string. The registry value is iTimePrefix for compatibility with previous Asian versions of Windows. The specifier must have one of the following values. No user-specified values are allowed. It is preferred for your application to use the LOCALE_STIMEFORMAT constant instead of LOCALE_ITIMEMARKPOSN.

    Value Meaning
    0 Use as suffix.
    1 Use as prefix.
  • LOCALE_ITLZERO
    Specifier for leading zeros in time fields. The specifier can be one of the following values. It is preferred for your application to use the LOCALE_STIMEFORMAT constant instead of LOCALE_ITLZERO.

    Value Meaning
    0 No leading zeros for hours.
    1 Leading zeros for hours.
  • LOCALE_SABBREVCTRYNAME
    Abbreviated name of the country/region, mostly based on the ISO Standard 3166. The maximum number of characters allowed for this string is nine, including a terminating null character.

  • LOCALE_SABBREVDAYNAME1
    Native abbreviated name for Monday. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVDAYNAME2
    Native abbreviated name for Tuesday. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVDAYNAME3
    Native abbreviated name for Wednesday. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVDAYNAME4
    Native abbreviated name for Thursday. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVDAYNAME5
    Native abbreviated name for Friday. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVDAYNAME6
    Native abbreviated name for Saturday. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVDAYNAME7
    Native abbreviated name for Sunday. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVLANGNAME
    Abbreviated name of the language. In most cases it is created by taking the two-letter language abbreviation from the ISO Standard 639 and adding a third letter, as appropriate, to indicate the sublanguage. For example, the abbreviated name for the language corresponding to the English (United States) locale is ENU.

  • LOCALE_SABBREVMONTHNAME1
    Native abbreviated name for January. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVMONTHNAME2
    Native abbreviated name for February. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVMONTHNAME3
    Native abbreviated name for March. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVMONTHNAME4
    Native abbreviated name for April. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVMONTHNAME5
    Native abbreviated name for May. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVMONTHNAME6
    Native abbreviated name for June. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVMONTHNAME7
    Native abbreviated name for July. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVMONTHNAME8
    Native abbreviated name for August. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVMONTHNAME9
    Native abbreviated name for September. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVMONTHNAME10
    Native abbreviated name for October. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVMONTHNAME11
    Native abbreviated name for November. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVMONTHNAME12
    Native abbreviated name for December. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SABBREVMONTHNAME13
    Native abbreviated name for 13th month, if it exists. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SCONSOLEFALLBACKNAME
    Windows Vista and later: Preferred locale to use for console display. The maximum number of characters allowed for this string is 85, including a terminating null character. See also Locale Name Constants.

    Note   In general, applications should not make direct use of LOCALE_SCONSOLEFALLBACKNAME data. To determine what language resources to use in a console window, an application should call either SetThreadUILanguage or SetThreadPreferredUILanguages. These functions use the console fallback data as a factor in choosing a language that is legible in the console, but it is not the sole determinant. In particular, the console is limited to displaying characters from a single code page. For example, "el-GR" for Greek (Greece) is a valid console language, but if the current console code page is Latin-1 (code page 1252) the console displays Greek text mostly as a series of character-not-found symbols.

  • LOCALE_SCOUNTRY
    Full localized name of the country/region. The maximum number of characters allowed for this string is 80, including a terminating null character. This name is based on the localization of the product. Thus it changes for each localized version.

  • LOCALE_SDAYNAME1
    Native long name for Monday. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SDAYNAME2
    Native long name for Tuesday. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SDAYNAME3
    Native long name for Wednesday. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SDAYNAME4
    Native long name for Thursday. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SDAYNAME5
    Native long name for Friday. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SDAYNAME6
    Native long name for Saturday. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SDAYNAME7
    Native long name for Sunday. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SDURATION
    Windows Vista and later: Time duration format. The format is similar to the format for LOCALE_STIMEFORMAT. Like LOCALE_STIMEFORMAT, this format can also include any string of characters enclosed in single quotes. Formats could include, for example, "h:mm:ss", or "d'd 'h'h 'm'm 's.fff's'". In comparison with LOCALE_STIMEFORMAT:

    • There are additional format pictures for fractions of a second.
    • Because this format is for duration, not time, it does not specify a 12- or 24-hour clock system, nor include an AM/PM indicator.

    This might be used, for example, for a multimedia application that displays file time or a sporting event application that displays finish times.

    The following is a complete list of the available format pictures:

    Value Meaning
    h Hours without leading zeros for single-digit hours
    hh Hours with leading zeros for single-digit hours
    m Minutes without leading zeros for single-digit minutes
    mm Minutes with leading zeros for single-digit minutes
    s Seconds without leading zeros for single-digit seconds
    ss Seconds with leading zeros for single-digit seconds
    f Tenths of a second
    ff Hundredths of a second
    fff Thousandths of a second; character 'f' can occur up to nine consecutive times (fffffffff), although support for frequency timers is limited to 100 nanoseconds; if nine are present, the last two digits are always zero
  • LOCALE_SENGCOUNTRY
    Full English name of the country/region. The maximum number of characters allowed for this string is 80, including a terminating null character. This name is always restricted to characters that can be mapped into the ASCII 127-character subset.

  • LOCALE_SENGCURRNAME
    Windows 98/Me, Windows 2000 and later: The full English name of the currency associated with the locale. There is no limit on the number of characters allowed for this string.

  • LOCALE_SENGLANGUAGE
    Full English name of the language from the International Organization for Standardization (ISO) Standard 639. There is no limit on the number of characters allowed for this string. This name is always restricted to characters that can be mapped into the ASCII 127-character subset. It is not always equivalent to the English version of LOCALE_SLANGUAGE.

  • LOCALE_SINTLSYMBOL
    Three characters of the international monetary symbol specified in ISO 4217, followed by the character separating this string from the amount. The maximum number of characters allowed for this string is nine, including a terminating null character.

  • LOCALE_SIETFLANGUAGE
    Windows Vista and later: Deprecated. This constant is removed for the Windows Vista release.

  • LOCALE_SISO3166CTRYNAME
    Windows 98/Me, Windows NT 4.0 and later: Country/region name, based on ISO Standard 3166, for example, "US" for the United States. The maximum number of characters allowed for this string is nine, including a terminating null character.

  • LOCALE_SISO3166CTRYNAME2
    Windows Vista and later: Three-letter ISO region name (ISO 3166 three-letter code for the country/region), for example, "USA" for the United States. The maximum number of characters allowed for this string is nine, including a terminating null character.

  • LOCALE_SISO639LANGNAME
    Windows 98/Me, Windows NT 4.0 and later: The abbreviated name of the language based entirely on the ISO Standard 639 values, in lowercase form, for example, "en" for English. The maximum number of characters allowed for this string is nine, including a terminating null character.

  • LOCALE_SISO639LANGNAME2
    Windows Vista and later: Three-letter ISO language name, in lowercase form (ISO 639-2 three-letter code for the language), for example, "eng" for English. The maximum number of characters allowed for this string is nine, including a terminating null character.

  • LOCALE_SKEYBOARDSTOINSTALL
    Windows Vista and later: A semicolon-delimited list of keyboards to potentially install for the locale and to be used internally by Windows. There is no limit on the number of characters allowed for this string. To retrieve the name of the active input locale identifier (formerly called the keyboard layout), your application can call the GetKeyboardLayoutName function.

  • LOCALE_SLANGDISPLAYNAME
    Windows Vista and later: Primary language name included in a localized display name. For example, in the locale/language name "en-US" for English (United States), this constant represents "en".

  • LOCALE_SLANGUAGE
    Full localized name of the language. There is no limit on the number of characters allowed for this string. This name is based on the localization of the product. Therefore, the value changes for each localized version.

  • LOCALE_SMONTHNAME1
    Native long name for January. The maximum number of characters allowed for this string is 80, including a terminating null character. Calling the GetLocaleInfo or GetLocaleInfoEx function with a LOCALE_SMONTHNAMExx constant returns the stand-alone, or nominative, form of the month name. To get the genitive form of the month name, the application calls GetDateFormat or GetDateFormatEx with a date picture of ddMMMM and removes the two digits from the beginning of the retrieved string.

  • LOCALE_SMONTHNAME2
    Native long name for February. The maximum number of characters allowed for this string is 80, including a terminating null character. See note for LOCALE_SMONTHNAME1.

  • LOCALE_SMONTHNAME3
    Native long name for March. The maximum number of characters allowed for this string is 80, including a terminating null character. See note for LOCALE_SMONTHNAME1.

  • LOCALE_SMONTHNAME4
    Native long name for April. The maximum number of characters allowed for this string is 80, including a terminating null character. See note for LOCALE_SMONTHNAME1.

  • LOCALE_SMONTHNAME5
    Native long name for May. The maximum number of characters allowed for this string is 80, including a terminating null character. See note for LOCALE_SMONTHNAME1.

  • LOCALE_SMONTHNAME6
    Native long name for June. The maximum number of characters allowed for this string is 80, including a terminating null character. See note for LOCALE_SMONTHNAME1.

  • LOCALE_SMONTHNAME7
    Native long name for July. The maximum number of characters allowed for this string is 80, including a terminating null character. See note for LOCALE_SMONTHNAME1.

  • LOCALE_SMONTHNAME8
    Native long name for August. The maximum number of characters allowed for this string is 80, including a terminating null character. See note for LOCALE_SMONTHNAME1.

  • LOCALE_SMONTHNAME9
    Native long name for September. The maximum number of characters allowed for this string is 80, including a terminating null character. See note for LOCALE_SMONTHNAME1.

  • LOCALE_SMONTHNAME10
    Native long name for October. The maximum number of characters allowed for this string is 80, including a terminating null character. See note for LOCALE_SMONTHNAME1.

  • LOCALE_SMONTHNAME11
    Native long name for November. The maximum number of characters allowed for this string is 80, including a terminating null character. See note for LOCALE_SMONTHNAME1.

  • LOCALE_SMONTHNAME12
    Native long name for December. The maximum number of characters allowed for this string is 80, including a terminating null character. See note for LOCALE_SMONTHNAME1.

  • LOCALE_SMONTHNAME13
    Native name for 13th month, if it exists. The maximum number of characters allowed for this string is 80, including a terminating null character. See note for LOCALE_SMONTHNAME1.

  • LOCALE_SNAME
    Windows Vista and later: Locale name, a multipart tag to uniquely identify this locale. The maximum number of characters allowed for this string is 85, including a terminating null character. The tag is based on the language tagging conventions of RFC 4646. The pattern to use is described in Locale Names. See also Locale Name Constants

  • LOCALE_SNAN
    Windows Vista and later: String value for "Not a number", for example, "Nan" for the English (United States) locale. There is no limit on the number of characters allowed for this string.

  • LOCALE_SNATIVECTRYNAME
    Native name of the country/region, for example, España for the Spanish (Spain) locale. The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SNATIVECURRNAME
    Windows 98/Me, Windows 2000 and later: The native name of the currency associated with the locale, in the native language of this locale. There is no limit on the number of characters allowed for this string.

  • LOCALE_SNATIVELANGNAME
    Native name of the language, for example, Հայերեն for Armenian (Armenia). The maximum number of characters allowed for this string is 80, including a terminating null character.

  • LOCALE_SNEGINFINITY
    Windows Vista and later: String value for "negative infinity", for example, "-Infinity" for the English (United States) locale. There is no limit on the number of characters allowed for this string.

  • LOCALE_SPARENT
    Windows Vista and later: Fallback locale, used by the resource loader. The maximum number of characters allowed for this string is 85, including a terminating null character. See also Locale Name Constants.

    Locales have a hierarchy in which the parent of a specific locale is a neutral locale. A specific locale is associated with both a language and a country/region while a neutral locale is associated with a language but is not associated with any country/region. The parent locale is used to decide the first fallback to be tried when a resource for a specific locale is not available. For example, the parent locale for "en-US" (0x0409) is "en" (0x0009). When a resource is not available for the specific "en-US" locale, the resource loader falls back to use the resource that is available for the neutral "en" locale. See Language Preferences and Fallbacks for further details of the resource loader fallback strategy.

    This pattern is consistent for predefined locales. However, the parent locale is not determined by any manipulation of the locale name. That is, GetLocaleInfo and GetLocaleInfoEx do not parse a string such as "en-US" to get the value "en". Instead, they look at the stored locale data. For predefined locales, the value follows follow the expected pattern, in which the parent of a specific locale is the corresponding neutral locale and the parent of a neutral locale is the invariant locale. While it is recommended that custom locales follow a similar strategy in terms of defining their parent locale, this is not enforced. The application implementing a custom locale can specify a less obviously appropriate parent.

    Note   None of the functions described in "Locale Name" Functions accept neutral locales as inputs, so this LOCALE_SPARENT data is of very limited use. In particular, neither GetLocaleInfo nor GetLocaleInfoEx accepts neutral locales as inputs.

  • LOCALE_SPOSINFINITY
    Windows Vista and later: String value for "positive infinity", for example, "Infinity" for the English (United States) locale. There is no limit on the number of characters allowed for this string.

  • LOCALE_SSCRIPTS
    Windows Vista and later: A string representing a list of scripts, using the 4-character notation used in ISO 15924 Non-Microsoft link. Each script name consists of four Latin characters, and the list is arranged in alphabetical order, with each name, including the last, followed by a semicolon.

    GetLocaleInfo or GetLocaleInfoEx can be called with LCType set to this value as part of a strategy to mitigate security issues related to Internationalized Domain Names (IDNs).

    Here are some example values:

    Locale Locale/language name Value
    English (United States) en-US Latn;
    Hindi (India) hi-IN Deva;
    Japanese (Japan) ja-JP Hani;Hira;Kana;

    A compound script value does not include the Latin script unless it is an essential part of the writing system used for the particular locale. Latin characters are often used in the context of locales for which they are not native, for example, for a foreign business name. In the example above for Hindi in India, the only script value is "Deva" (for "Devanagari"), although Latin characters can also appear in Hindi text. The VerifyScripts function has a special flag to address this case.

  • LOCALE_SSHORTESTDAYNAME1
    Windows Vista and later: Short native name of the first day of the week. This name is often shorter than LOCALE_SABBREVDAYNAME1, and it is useful for calendar titles.

  • LOCALE_SSHORTESTDAYNAME2
    Windows Vista and later: Short native name of the second day of the week. This name is often shorter than LOCALE_SABBREVDAYNAME2, and it is useful for calendar titles.

  • LOCALE_SSHORTESTDAYNAME3
    Windows Vista and later: Short native name of the third day of the week. This name is often shorter than LOCALE_SABBREVDAYNAME3, and it is useful for calendar titles.

  • LOCALE_SSHORTESTDAYNAME4
    Windows Vista and later: Short native name of the fourth day of the week. This name is often shorter than LOCALE_SABBREVDAYNAME4, and it is useful for calendar titles.

  • LOCALE_SSHORTESTDAYNAME5
    Windows Vista and later: Short native name of the fifth day of the week. This name is often shorter than LOCALE_SABBREVDAYNAME5, and it is useful for calendar titles.

  • LOCALE_SSHORTESTDAYNAME6
    Windows Vista and later: Short native name of the sixth day of the week. This name is often shorter than LOCALE_SABBREVDAYNAME6, and it is useful for calendar titles.

  • LOCALE_SSHORTESTDAYNAME7
    Windows Vista and later: Short native name of the seventh day of the week. This name is often shorter than LOCALE_SABBREVDAYNAME7, and it is useful for calendar titles.

  • LOCALE_SSORTNAME
    Windows 98/Me, Windows 2000 and later: The full localized name of the sort for the specified locale identifier, dependent on the language of the shell.

Many of the locale types previously listed are closely related, so that changing one affects the value of the others. The following table shows the relationships among these types.

Constant Affects
LOCALE_ICURRENCY LOCALE_IPOSSEPBYSPACE, LOCALE_IPOSSYMPRECEDES
LOCALE_INEGCURR LOCALE_SPOSITIVESIGN, LOCALE_INEGSEPBYSPACE, LOCALE_INEGSYMPRECEDES, LOCALE_INEGSIGNPOSN, LOCALE_IPOSSIGNPOSN
LOCALE_SSHORTDATE LOCALE_SDATE, LOCALE_IDATE, LOCALE_ICENTURY, LOCALE_IDAYLZERO, LOCALE_IMONLZERO
LOCALE_SLONGDATE LOCALE_ILDATE
LOCALE_STIMEFORMAT LOCALE_STIME, LOCALE_ITIME, LOCALE_ITLZERO, LOCALE_ITIMEMARKPOSN