Events
May 19, 6 PM - May 23, 12 AM
Calling all developers, creators, and AI innovators to join us in Seattle @Microsoft Build May 19-22.
Register todayThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Converts a local time to a time in Coordinated Universal Time (UTC).
BOOL TzSpecificLocalTimeToSystemTime(
[in, optional] const TIME_ZONE_INFORMATION *lpTimeZoneInformation,
[in] const SYSTEMTIME *lpLocalTime,
[out] LPSYSTEMTIME lpUniversalTime
);
[in, optional] lpTimeZoneInformation
A pointer to a TIME_ZONE_INFORMATION structure that specifies the time zone for the time specified in lpLocalTime.
If lpTimeZoneInformation is NULL, the function uses the currently active time zone.
[in] lpLocalTime
A pointer to a SYSTEMTIME structure that specifies the local time to be converted. The function converts this time to the corresponding UTC time.
[out] lpUniversalTime
A pointer to a SYSTEMTIME structure that receives the UTC time.
If the function succeeds, the return value is nonzero, and the function sets the members of the SYSTEMTIME structure pointed to by lpUniversalTime to the appropriate values.
If the function fails, the return value is zero. To get extended error information, call GetLastError.
TzSpecificLocalTimeToSystemTime takes into account whether daylight saving time (DST) is in effect for the local time to be converted.
Requirement | Value |
---|---|
Minimum supported client | Windows XP [desktop apps | UWP apps] |
Minimum supported server | Windows Server 2003 [desktop apps | UWP apps] |
Target Platform | Windows |
Header | timezoneapi.h (include Windows.h) |
Library | Kernel32.lib |
DLL | Kernel32.dll |
Events
May 19, 6 PM - May 23, 12 AM
Calling all developers, creators, and AI innovators to join us in Seattle @Microsoft Build May 19-22.
Register today