The published date String is returned as : Sun, 18 Nov 2012 06:50:02 GMT and my method to convertDate is returning me java.text.ParseException: Unparseable date: "Sun, 18 Nov 2012 06:50:02 GMT" (at offset 8). I checked resources but couldn't find them much helpful like this one ... Parsing a String with a GMT timezone to Date using SimpleDateFormat
Would really appreciate if you can shed some light on it. Here is my method .. pubDate here is Sun, 18 Nov 2012 06:50:02 GMT
public Date convertDate(String pubDate){
SimpleDateFormat sdf = new SimpleDateFormat("EEE, dd MM yyyy hh:mm:ss Z",Locale.US);
Date newsDate = new GregorianCalendar(0, 0, 0).getTime();
try{
newsDate = sdf.parse(pubDate);
}catch(ParseException e){
Log.d(Tag, "Exception Parsing date" + pubDate);
}
return null;
}