Difference between 2 dates
Posted on 2004-04-15
I have seen most of the solutions found here. But I am having trouble with the calulation of the number of days when using 04/01/2004 to 04/30/2004 is calculating 29 days instead of 30. But when I use something like 04/01/2004 - 04/03/2004 it is calcualting 3 days which is correct. Also it is correct when I use 4/5/2004 - 04/30/2004. it appears to only give an incorrect number when I use a start date from standard time and a end date from daylight savings time.
Anyone else experience this?
I am using the difference in milliseconds, diffMilli/(24*60*60*1000).