I am collecting data from the call log. This is how I format the date of the call to my taste:
DateFormat datePattern = DateFormat.getDateInstance(DateFormat.FULL); //Tuesday, October 18, 2011
Long datelong = Long.parseLong("1318950779497");
String date_str = datePattern.format(datelong);
Date date = new Date(date_str);
formatter = new SimpleDateFormat("d/M/yyyy"); //18/10/2011
newdateformatted = formatter.format(date);
This the time of the call:
DateFormat timePattern = DateFormat.getTimeInstance(DateFormat.LONG); //12:40:32 PM GMT+00:00
How can I format this? I want the 24 hour time code.