Export (0) Print
Expand All

MAKELANGID macro

Creates a language identifier from a primary language identifier and a sublanguage identifier.

Syntax


WORD MAKELANGID(
  USHORT usPrimaryLanguage,
  USHORT usSubLanguage
);

Parameters

usPrimaryLanguage

Primary language identifier. This identifier can be a predefined value or a value for a user-defined primary language. For a user-defined language, the identifier is a value in the range 0x0200 to 0x03FF. All other values are reserved for operating system use. For more information, see Language Identifier Constants and Strings.

usSubLanguage

Sublanguage identifier. This parameter can be a predefined sublanguage identifier or a user-defined sublanguage. For a user-defined sublanguage, the identifier is a value in the range 0x20 to 0x3F. All other values are reserved for operating system use. For more information, see Language Identifier Constants and Strings.

Return value

Returns the language identifier.

Remarks

The following table shows combinations of usPrimaryLanguage and usSubLanguage that have special meaning.

Primary language identifierSublanguage identifierMeaning
LANG_NEUTRALSUBLANG_NEUTRALLanguage neutral
LANG_NEUTRALSUBLANG_DEFAULTUser default language
LANG_NEUTRALSUBLANG_SYS_DEFAULTSystem default language
LANG_NEUTRALSUBLANG_CUSTOM_DEFAULTWindows Vista and later: Default custom locale
LANG_NEUTRALSUBLANG_CUSTOM_UNSPECIFIEDWindows Vista and later: Unspecified custom locale
LANG_NEUTRALSUBLANG_UI_CUSTOM_DEFAULTWindows Vista and later: Default custom Multilingual User Interface locale

 

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Winnt.h (include Windows.h)

See also

National Language Support
National Language Support Macros
EnumSystemLocales
PRIMARYLANGID
SUBLANGID

 

 

Community Additions

ADD
Show:
© 2014 Microsoft