Java - How to get current year?
Posted
by Yatendra Goel
on Stack Overflow
See other posts from Stack Overflow
or by Yatendra Goel
Published on 2010-05-23T12:08:26Z
Indexed on
2010/05/23
12:10 UTC
Read the original article
Hit count: 275
I want to know the current Date and Time.
The code
Calendar.getInstance();
represents a date and time of the system on which the program is running and the system date can be wrong.
So Is there any way by which I can get correct current date and time irrespective of the date and time of the system on which program is running?
© Stack Overflow or respective owner