Search code examples
androiddateepoch

Android epoch wrong time


By using the below code i get 43753-07-31T04:40:44-0500

long installed = 1318562444444;
SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ssZ");
String dateString = formatter.format(new Date(installed * 1000L));

HELP :(


Solution

  • Installed is already in milliseconds.