EventDateTime d1 = event.getStart();
SimpleDateFormat outputFormat = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSS'Z'");
String outputDate = outputFormat.format(d1.getDate());
我无法在String中获取日期。
答案 0 :(得分:1)
EventDateFormat.getDate()
得到了
The date, in the format "yyyy-mm-dd", if this is an all-day event.
您可能希望改为使用getDateTime()。