• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

how to quickly get current year/month ?

 
Steve Mutanson
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How to quickly get current year and month ? I guess there are different ways but can somebody show me an easy way ?
thanks,
 
Michael Dunn
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
One of the ways
 
Jamie Robertson
Ranch Hand
Posts: 1879
MySQL Database Suse
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
if you just want a String representation of the current date, use the SimpleDateFormat class:

Jamie
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic