Possible Duplicate:
Android: how to get the current day of the week (Monday, etc…) in user language?
I want to get the date of the specific day in java for android application development. eg. For Sunday 7.8.2011 14.8.2011 21.8.2011
Possible Duplicate:
Android: how to get the current day of the week (Monday, etc…) in user language?
I want to get the date of the specific day in java for android application development. eg. For Sunday 7.8.2011 14.8.2011 21.8.2011
Date date1 = (new GregorianCalendar(2011 , Calendar.AUGUST, 28)).getTime();
Format formatter = new SimpleDateFormat("EEEE");
String s = formatter.format(date1); // s==Sunday
Take a look at the Calendar
Class. You can instantiate it using the Calendar.getInstance()
method.
http://download.oracle.com/javase/1.5.0/docs/api/java/util/Calendar.html
i think its something like this cal.get(Calendar.DAY_OF_WEEK)