Here's how you can do it using Java nio
BasicFileAttributes attr = Files.readAttributes(filePath, BasicFileAttributes.class);
DateFormat df = new SimpleDateFormat("yyyy/MM/dd");
Date d = new Date(attr.creationTime().toMillis());
System.out.println(df.format(d));