I have string "1/28/2013 3:26:51 PM"
SimpleDateFormat formatter = new SimpleDateFormat("M/dd/yyyy h:mm:ss a");
try {
this.createDate = formatter.parse(xmlPhoto.getCreateDate());
this.shootDate = formatter.parse(xmlPhoto.getShootDate());
} catch (ParseException e) {
e.printStackTrace();
}
I want to make a Date object from this String, but I get a ParseExceprion and offset = 19.
The
AM/PMmarker may not be be matching with that from your defaultLocale. try with: