Quantcast
Channel: web development helpdesk » time
Viewing all articles
Browse latest Browse all 3

How to calculate the difference between two Date’s or times

$
0
0
Problem is you have two Date instances and you want to get the elapsed time between them. Getting the number of seconds is easy, you can just take the difference of value returned by the getTime() method. long elapsed = end.getTime() - start.getTime(); But what if you want to know how many days, hours and […]

Viewing all articles
Browse latest Browse all 3

Latest Images

Trending Articles





Latest Images