• Post Reply Bookmark Topic Watch Topic
  • New Topic

how to get date in YYYYMMDD format  RSS feed

 
shama parween
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi ,

In whatever the format we enter the date, it should check if its a valid date and should return in YYYYMMDD format without any spaces,slash aur hyphen.
Please help me with this.
 
Jesper de Jong
Java Cowboy
Sheriff
Posts: 16060
88
Android IntelliJ IDE Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Use class SimpleDateFormat to format your Date object into a string with the desired format. See the API documentation of class SimpleDateFormat to find out how to do it exactly.
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!