This section shows the way of getting the current date of the system.
In this section, through the given program you can get the current date in the proper format (Day/Month/Year). This program shows the current date by using the various methods and fields of the Calendar class. These are explained as follows:
This field of the Calendar class returns the static integer which is the value of the month of the year.
This field returns a static integer value which is the value of the day of the month in the year.
This field returns a static integer value which is the current year.
Here is the code of the program:
Posted on: April 16, 2007 If you enjoyed this post then why not add us on Google+? Add us to your Circles