Hi Friends,
This is not specific to servlet, but it's more of core java query.
I have create time instance in miliseconds. Need to get the diff. And want to
diplay again in time (but not within 24 hrs range).
Here is code I am using :
java.util.Date date = new java.util.Date();
java.sql.Date dt = new java.sql.Date(date.getTime()); // dt=yyyy-mm-dd
java.sql.Time t1 = new java.sql.Time(date.getTime());
java.sql.Time t2 = new java.sql.Time(date.getTime()+(25*24*60*1000));
// i.e. Diff between t2 and t1 is of 25 Hours
How can I calculate the diff for t2 and t1, which should display as 25:00:00
Vipul
____________________________________________________________________
Get free email and a permanent address at http://www.netaddress.com/?N=1
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html