EnumLanguageGroupLocalesA function (winnls.h)
Enumerates the locales in a specified language group.
Syntax
BOOL EnumLanguageGroupLocalesA(
[in] LANGGROUPLOCALE_ENUMPROCA lpLangGroupLocaleEnumProc,
[in] LGRPID LanguageGroup,
[in] DWORD dwFlags,
[in] LONG_PTR lParam
);
Parameters
[in] lpLangGroupLocaleEnumProc
Pointer to an application-defined callback function. For more information, see EnumLanguageGroupLocalesProc.
[in] LanguageGroup
Identifier of the language group for which to enumerate locales. This parameter can have one of the following values:
- LGRPID_ARABIC
- LGRPID_ARMENIAN
- LGRPID_BALTIC
- LGRPID_CENTRAL_EUROPE
- LGRPID_CYRILLIC
- LGRPID_GEORGIAN
- LGRPID_GREEK
- LGRPID_HEBREW
- LGRPID_INDIC
- LGRPID_JAPANESE
- LGRPID_KOREAN
- LGRPID_SIMPLIFIED_CHINESE
- LGRPID_TRADITIONAL_CHINESE
- LGRPID_THAI
- LGRPID_TURKIC
- LGRPID_TURKISH
- LGRPID_VIETNAMESE
- LGRPID_WESTERN_EUROPE
[in] dwFlags
Reserved; must be 0.
[in] lParam
An application-defined value to pass to the callback function. This value can be used for error checking. It can also be used to ensure thread safety in the callback function.
Return value
Returns a nonzero value if successful, or 0 otherwise. To get extended error information, the application can call GetLastError, which can return one of the following error codes:
- ERROR_BADDB. The function could not access the data. This situation should not normally occur, and typically indicates a bad installation, a disk problem, or the like.
- ERROR_INVALID_FLAGS. The values supplied for flags were not valid.
- ERROR_INVALID_PARAMETER. Any of the parameter values was invalid.
Remarks
This function enumerates locales in the specified language group by passing locale identifiers, one at a time, to the application-defined callback function. This process continues until EnumLanguageGroupLocales finds the last locale identifier or the callback function returns FALSE.
Note
The winnls.h header defines EnumLanguageGroupLocales as an alias that automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that is not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 2000 Professional [desktop apps only] |
Minimum supported server | Windows 2000 Server [desktop apps only] |
Target Platform | Windows |
Header | winnls.h (include Windows.h) |
Library | Kernel32.lib |
DLL | Kernel32.dll |