I think that the registry entries are (Exported from my registry)
======================================
[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\TimeZoneInformation]
"Bias"=dword:00000000
"StandardName"="GMT : Greenwich Mean Time"
"StandardBias"=dword:00000000
"StandardStart"=hex:00,00,0a,00,05,00,02,00,00,00,00,00,00,00,00,00
"DaylightName"="BST : British Summer Time"
"DaylightBias"=dword:ffffffc4
"DaylightStart"=hex:00,00,03,00,05,00,01,00,00,00,00,00,00,00,00,00
"ActiveTimeBias"=dword:00000000
======================================

The standard start and daylight start are coded (sorry I don't know how but I 
gather the form is nth xday from one end of the month or the other of a given 
month) ... this should enable you to determine if the date was in  or not in 
the daylight saving portion of the year by the CURRENT standard. The bias 
numbers are the offset from GMT is minutes with a -ve number indicating a more 
ADVANCED time (eg in mine ffffffc4 or -60 indicates that BST is 60 minutes in 
front of GMT.

Allan

--- In [email protected], mauro russo <m.ru...@...> wrote:
>
> Really, I do not know if a standard exists, valid in every country around the 
> world.
> 
> For example, in Italy (where I am) the last change was last sunday in october,
> and always at 3:00 AM, not 2:00 AM.
> 
> Thanks for any help.
> 
> 
>   ----- Original Message ----- 
>   From: Glenn B. Lawler 
>   To: '[email protected]' 
>   Sent: Monday, November 09, 2009 10:43 PM
>   Subject: RE: [delphi-en] conversions between UTC and local time
> 
> 
>     
>   Mauro,
> 
>   >is there at least some API giving the "next time" there will be a change 
> on local time
>   >with respect UTC?
> 
>   Why not just calculate the dates yourself? The rules have changed over the 
> years,
>   AFAIK, the current rules are:
> 
>   1. 2nd Sunday in March at 2:00 AM, add one hour.
> 
>   2. 1st Sunday in November at 2:00 AM, subtract one hour.
> 
>   There are a number of ways to calculate the next date based on these rules.
> 
>   Check the Delphi help on EncodeDate, DecodeDate, and
>   DayOfWeek.
> 
>   The TDateTime type is a double (floating point) number. The
>   integral part is the number of days since a particular reference
>   date (+/-) and the fractional part is the fraction of a day to
>   represent the time. We don't need the time for this problem.
> 
>   Think about the simplest approach you could use to manually
>   determine the date of the Nth day of the week in a given month.
> 
>   Write a function that returns the date of the next daylight change
>   given a starting date.
> 
>   Let us know if you need help on the particulars of implementing
>   this. While this problem may seem difficult at first, the way to
>   deal with it (or any other non-trivial problem) is to break it down
>   into simpler steps which can individually be solved easily.
> 
>   Glenn Lawler
>   www.incodesystems.com
> 
>   -----Original Message-----
>   From: mauro russo [SMTP:m.ru...@...]
>   Sent: Monday, November 09, 2009 1:48 PM
>   To: [email protected]
>   Subject: Re: [delphi-en] conversions between UTC and local time
> 
>   Dear,
> 
>   is there at least some API giving the "next time" there will be a change on 
> local time
>   with respect UTC?
> 
>   ----- Original Message ----- 
>   From: Rob Kennedy 
>   To: [email protected] 
>   Sent: Tuesday, October 27, 2009 3:31 PM
>   Subject: Re: [delphi-en] conversions between UTC and local time
> 
>   mauro russo wrote:
>   > Dear all,
>   > 
>   > I am using the following function in order to obtain the bias between 
> local time and UTC:
>   > 
>   > 
>   > function GetTimeZoneBias_min(): Integer;
>   > var tz: TTimeZoneInformation;
>   > begin
>   > case GetTimeZoneInformation(tz) of
>   > TIME_ZONE_ID_STANDARD: Result := -(tz.StandardBias + tz.Bias);
>   > TIME_ZONE_ID_DAYLIGHT: Result := -(tz.DaylightBias + tz.Bias);
>   > else
>   > Result := 0;
>   > end;
>   > end;
>   > 
>   > 
>   > and I use the result Res in the formula: locla_time = UTC + Res.
>   > 
>   > 
>   > 
>   > Now, I would like to obtain the bias not at the current time, but 
> according to a given UTC value.
>   > 
>   > For example, now UTC is 9:47 at the 27th of october,
>   > but how to obtain the bias when UTC was, for example, 8:35 at the 5th of 
> july?
> 
>   If the StandardDate and DaylightDate members of TTimeZoneInformation 
>   don't have what you need, then Windows does not have what you need.
> 
>   -- 
>   Rob
> 
>   ----------
> 
>   Questa email e stata verificata dal sistema centralizzato antivirus della 
> UniPlan Software
> 
>   [Non-text portions of this message have been removed]
> 
>   ------------------------------------
> 
>   -----------------------------------------------------
>   Home page: http://groups.yahoo.com/group/delphi-en/
>   To unsubscribe: delphi-en-unsubscr...@...! Groups Links
> 
> 
> 
>   
>   ----------
> 
> Questa email รจ stata verificata dal sistema centralizzato antivirus della 
> UniPlan Software
> 
> 
> [Non-text portions of this message have been removed]
>


Reply via email to