Stuart McLachlan
stuart at lexacorp.com.pg
Sat Oct 18 19:07:54 CDT 2003
On 18 Oct 2003 at 17:33, Henry Simpson wrote: > Christian: > > If one were using an fluctuating base 365/366 number system, that would be > close, but that is unnecessarily complicated. The integer portion is > usually a count of days before or after the date: > > ?format(cdate(0), "dd mm yyyy") > 30 12 1899 > Since Dates are really just doubles, you don't really even need the CDate() here, just Format(0,"dd mm yyyy"). > which is December 30, 1899. Negative numbers are days prior to that day. > > If you replace the 0 with a 2, you get January 1, 1900 and if you use 367, > you get the first day of the 20th century, January 1, 1901. There's > Microsoft logic shining as it often does. > That strikes me quite often when I'm doing date manipulation. I've tried to see the reasoning behind that start date. So far, I can't see it at all. Can anyone come with *any* logical reason? Especially when you consider that Excel uses a more logical scheme where Day 1 is "1 Jan 1900" Still in some ways Access is better than Excel which returns "O Jan 1900" for Day 0 and an error for negative numbers :-) -- Lexacorp Ltd http://www.lexacorp.com.pg Information Technology Consultancy, Software Development,System Support.