0

Hello i am new in android. Can anybody help me to find how i get date format Sun 15th July from 2012-07-15? I found examples but each of it is for various different date-formats. Please help me to find this.

Hardik Joshi
  • 9,477
  • 12
  • 61
  • 113
  • Take a look at this thread. http://stackoverflow.com/questions/454315/how-do-you-format-date-and-time-in-android – mhan Jul 11 '12 at 10:40
  • Whatever format you want, [SimpleDateFormat](http://developer.android.com/reference/java/text/SimpleDateFormat.html) is the class. – Paresh Mayani Jul 11 '12 at 10:53

1 Answers1

1

try to get idea from my another answer in [Convert Date time in “April 6th, 2012 ” format][1]

[1]: Convert Date time in "April 6th, 2012 " format here you can only change the April to Sun and 2012 to month.

Like:-

DateFormatSymbols symbols = new DateFormatSymbols();
symbols.setShortWeekdays(new String[]{"Sun","Mon"....});
SimpleDateFormat format = new SimpleDateFormat("EE", symbols);

from this code you will get Days in "Sun,Mon,Tue..." Short Format

So pass this symbols in your SimpleDateFormat class.

Community
  • 1
  • 1
V.J.
  • 9,492
  • 4
  • 33
  • 49