Pete Cervasio schrieb:

 > Splitting the TDateTime into year, month etc. is done by a DecodeDate...

 > function, that *assumes* that TDateTime contains a local time. When you

 > feed it an UTC time, the result is unusable.

What? How does it assume it's in local time? It assumes it has received the value you want decoded. The value 40850.5 treated as a TDateTime is 03 NOV 2011 @ 12:00.

How do you get the starting date and time of the epoch?

According to Delphi help a TDateTime of 0.0 represents 12/30/1899 12:00 am, while Wikipedia states "start counting the seconds from the Unix epoch of 1970-01-01T00:00:00 UTC".

DoDi

_______________________________________________
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel

Reply via email to