Please help me to find a solution on this issue This is the date format I got form Json object
Sun Jan 08 00:00:00 GMT+05:30 2017.
I need to convert this date format to 2017-01-05
.
I implemented some code like this
android.text.format.DateFormat df = new android.text.format.DateFormat();
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd");
Date date1 = simpleDateFormat.parse(summary1.getDeliveryDate());
if(date1.equals(df.format("yyyy-MM-dd", new java.util.Date())))
{
spinnerArray.add("Cancel");
}
I am unable to enter in to loop... Please help me to find a solution