• Post Reply Bookmark Topic Watch Topic
  • New Topic

date conversion  RSS feed

 
raj baig
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi, all

i have a date in the format like 25-8-2006.
i want to change it into another format like : 2006-08-26
i tryed simpledateformat but no sufficient information.

thangs for suggestions.
 
Jesper de Jong
Java Cowboy
Sheriff
Posts: 16028
87
Android IntelliJ IDE Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i tryed simpledateformat but no sufficient information.

Well, your post also does not give us sufficient information. Show us the code that you wrote to do it with SimpleDateFormat.

Why didn't it work? Did you get an error? If yes, what error did you get? If it works but the output is not what you expect, then what did you expect and how does the actual output differ?
 
Sanjaya Sugiarto
Ranch Hand
Posts: 229
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How about if you simply define the locales (using getInstance (Locale alocale) in Calendar)? You want US locale, right?
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!