I'm working on an anadroid application where an user sees the data from certain vehicles including manufacturing date so far I've got it to work by making a method that transforms a string to date, giving it a date format so it'd recognize it.
private Date ToDate(String aDate) {
if(aDate==null) return null;
ParsePosition pos = new ParsePosition(0);
SimpleDateFormat simpledateformat = new SimpleDateFormat("yyyy-MM-dd");
Date stringDate = simpledateformat.parse(aDate, pos);
return stringDate;
}
It works fine when I add data to an arraylist, but when I want that data to be displayed it doesn't show the date in the format I gave it, it shows it like this
I have no idea what to do, even tried changing the date format again, but it still shows the date that way.
I must be missing something obvious, but I don't know what.