Platform SDK: International Features |
The EnumTimeFormats function enumerates the time formats that are available for a specified locale. The function enumerates the time formats by passing a pointer to a buffer containing a time format to an application defined–callback function. It continues to do so until the last time format is found or the callback function returns FALSE.
BOOL EnumTimeFormats( TIMEFMT_ENUMPROC lpTimeFmtEnumProc, // callback function LCID Locale, // locale DWORD dwFlags // unused );
Value | Meaning |
---|---|
LOCALE_SYSTEM_DEFAULT | Default system locale. |
LOCALE_USER_DEFAULT | Default user locale. |
Value | Meaning |
---|---|
LOCALE_USE_CP_ACP | Use the system ANSI code page for string translation instead of the locale's code page. |
If the function succeeds, the return values is a nonzero value.
If the function fails, the return value is zero. To get extended error information, call GetLastError. GetLastError may return one of the following error codes:
Windows 2000: The ANSI version of this function will fail if it is used with a Unicode-only LCID. See Language Identifiers.
Windows NT/2000: Requires Windows NT 3.5 or later.
Windows 95/98: Requires Windows 95 or later.
Header: Declared in Winnls.h; include Windows.h.
Library: Use Kernel32.lib.
Unicode: Implemented as Unicode and ANSI versions on Windows NT/2000.
National Language Support Overview, National Language Support Functions, EnumTimeFormatsProc, EnumCalendarInfo, EnumDateFormats