What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Skype & Technology » Tech Talk » Formula to calculate days lived?

Formula to calculate days lived?
Author: Message:
CookieRevised
Elite Member
*****

Avatar

Posts: 15519
Reputation: 173
– / Male / Flag
Joined: Jul 2003
Status: Away
RE: Formula to calculate days lived?
quote:
Originally posted by alby
I searched the net, I couldn't find much.
I searched the net and found tons :p

search with "Java Datediff" ;)

http://forum.java.sun.com/thread.jspa?threadID=48...&messageID=2292012
http://forum.java.sun.com/thread.jspa?forumID=31&threadID=395202
http://www.java2s.com/Code/Java/Development-Class...etweentwodates.htm
http://jalbum.net/api/se/datadosen/util/Dates.html
http://www.rupertjones.com/dateutil/docs/api/com/...util/DateDiff.html
etc

quote:
Originally posted by UTI
No... cause you'd need to add in leap years and such.
I dunno exactly for Java, but in any other language I know Date objects are in milliseconds or at least in seconds or another form which you can substract from each other.

You do not need to take in account leap years, lead days and leap seconds. This is automatically done as the calenders of the objects use Gregorian calenders.

But as said, I dunno if this is also the case in Java (but I would be surprised if it wasn't)...

This post was edited on 11-12-2006 at 12:43 AM by CookieRevised.
.-= A 'frrrrrrrituurrr' for Wacky =-.
11-12-2006 12:37 AM
Profile PM Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
Formula to calculate days lived? - by albert on 11-11-2006 at 09:14 PM
RE: Formula to calculate days lived? - by foaly on 11-11-2006 at 10:24 PM
RE: Formula to calculate days lived? - by qgroessl on 11-11-2006 at 10:25 PM
RE: Formula to calculate days lived? - by CookieRevised on 11-12-2006 at 12:37 AM
RE: Formula to calculate days lived? - by RaceProUK on 11-12-2006 at 03:44 PM
RE: Formula to calculate days lived? - by fluffy_lobster on 11-12-2006 at 08:18 PM
RE: RE: Formula to calculate days lived? - by rav0 on 11-13-2006 at 06:24 AM
RE: Formula to calculate days lived? - by RaceProUK on 11-12-2006 at 10:46 PM
RE: Formula to calculate days lived? - by Jarrod on 11-14-2006 at 10:58 AM


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On