03-02-2012 12:10 AM
Hi, I am referring this link for formatting my date.
I want my date to displayed like that ;
Wed, 29 Feb 2012 07: 22: 25GMT
DateFormat dateFormat = new SimpleDateFormat( "???, dd MMM yyyy HH: mm: ss'GMT'");
Calendar c = Calendar.getInstance(TimeZone.getTimeZone("GMT"));
c.setTime(new Date(miliseconds));
String formattedDate = dateFormat.format(c, new StringBuffer(), null).toString();
System.out.println(formattedDate);
Only "???" part is left. So if anyone has any idea then please help.
Solved! Go to Solution.
03-02-2012 12:15 AM
noopesh wrote:
Hi, I am referring this link for formatting my date.
I want my date to displayed like that ;
Wed, 29 Feb 2012 07: 22: 25GMTHow to get the day from the date...???
Like 29 feb,2012 day is Wed.
How to get that thing ?The remaining part I have done with this approach:DateFormat dateFormat = new SimpleDateFormat( "???, dd MMM yyyy HH: mm: ss'GMT'");
Calendar c = Calendar.getInstance(TimeZone.getTimeZone("GMT"));
c.setTime(new Date(miliseconds));
String formattedDate = dateFormat.format(c, new StringBuffer(), null).toString();
System.out.println(formattedDate);
Only "???" part is left. So if anyone has any idea then please help.
change the ??? to EEE
03-02-2012 01:14 AM