日期格式 system.currenttimemillis()
DateFormat system.currenttimemillis()
由于日期是毫秒格式,我该如何将其转换为 DD/MM/YY 格式??
Long Ldate = System.currentTimeMillis();
String date = Ldate.toString();
请使用此代码。这对你有帮助。
long time = System.currentTimeMillis();
SimpleDateFormat dayTime = new SimpleDateFormat("dd/MM/yy");
String str = dayTime.format(new Date(time));
由于日期是毫秒格式,我该如何将其转换为 DD/MM/YY 格式??
Long Ldate = System.currentTimeMillis();
String date = Ldate.toString();
请使用此代码。这对你有帮助。
long time = System.currentTimeMillis();
SimpleDateFormat dayTime = new SimpleDateFormat("dd/MM/yy");
String str = dayTime.format(new Date(time));