EnumSystemGeoNames function (winnls.h)
Enumerates the two-letter International Organization for Standardization (ISO) 3166-1 codes or numeric United Nations (UN) Series M, Number 49 (M.49) codes for geographical locations that are available on the operating system.
Syntax
BOOL EnumSystemGeoNames(
[in] GEOCLASS geoClass,
[in] GEO_ENUMNAMEPROC geoEnumProc,
[in, optional] LPARAM data
);
Parameters
[in] geoClass
The geographical location class for which to enumerate the available two-letter ISO 3166-1 or numeric UN M.49 codes.
[in] geoEnumProc
Pointer to the application-defined callback function Geo_EnumNameProc. The EnumSystemGeoNames function calls this callback function for each of the two-letter ISO 3166-1 or numeric UN M.49 codes for geographical locations that are available on the operating system until callback function returns FALSE.
[in, optional] data
Application-specific information to pass to the callback function that the genEnumProc parameter specifies.
Return value
Returns a nonzero value if successful, or 0 otherwise. To get extended error information, call GetLastError, which can return one of the following error codes:
Return code | Description |
---|---|
|
The values supplied for flags were not valid. |
|
A parameter value was not valid. |
Remarks
For information about two-letter ISO 3166-1 codes, see Country Codes - ISO 3166. For information about numeric UN M.49 codes, see Standard country or area codes for statistical use (M49).
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 10, version 1709 [desktop apps only] |
Minimum supported server | Windows Server 2016 [desktop apps only] |
Target Platform | Windows |
Header | winnls.h (include Windows.h) |
Library | Kernel32.lib |
DLL | Kernel32.dll |