I am trying to convert a String into Date... But the return value is wrong.
String startDate = \"2013-07-24\"; Date date = new Date(); try{ DateForm
Replace DD with dd to match the date.
DD
dd
DateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
As per the SimpledateFormat documentation
D Day in year d Day in month
D Day in year
d Day in month