Clive Walden wrote:
But that seems incredibly short sighted of Palm. Especially give all the Y2K issues!
There are still lots of people alive with dates of birth prior to 1904. And lots of legal entities
that started before 1904. Even more so in Europe than in the USA.
Most computers' clocks don't go back even that far. On Unix, it's 1970.
By the way, the reason for 1904 is the leap year rule: years that are
multiples of 4 are leap years, and the only exception is years that are
multiples of 100 but not also multiples of 400.
Thus, 1900 and 2100 are exceptions to the multiple-of-four rule, but
2000 is not. By restricting the range of valid dates so that it
doesn't go outside the range 1904 to 2096, you can just forget about
the exceptions and deal only with multiples of 4.
Unfortunately, if you really want to be accurate with dates in the
past, it can be difficult. You can certainly use the current calendar
to express any date in the past, but there is no guarantee that the
people at the place and the time used our current calendar. In fact,
the world didn't totally standardize on a universal calendar until
this century (well, last century -- the 20th one). Sometimes it's
not even possible to convert. The point is, extending our system
back into the past is of decreasing utility the further back you go.
Here's a fun illustration of how things were different even less
than 400 years ago:
http://www.tondering.dk/claus/calpic/tumba.html
Also, if you know Perl, the Date::Calc module has a lot of great
code you could refer to (to subtract dates, figure out day of the
week stuff, etc., etc.):
http://search.cpan.org/~stbey/Date-Calc-5.4/
(There are probably some C routines somewhere, too, of course, but
I can only give pointers to things I know about...)
- Logan
To unsubscribe send an email to [EMAIL PROTECTED]
--
For information on using the Palm Developer Forums, or to unsubscribe, please
see http://www.palmos.com/dev/support/forums/