如何以编程方式将日历事件设为 2012 年 10 月 29 日 18:00 的日期?我使用它,但我不太清楚如何将正确的值传递给这个日期。谢谢
Calendar cal = Calendar.getInstance();
Intent intent = new Intent(Intent.ACTION_EDIT);
intent.setType("vnd.android.cursor.item/event");
intent.putExtra("beginTime", cal.getTimeInMillis());
intent.putExtra("allDay", true);
intent.putExtra("rrule", "FREQ=YEARLY");
intent.putExtra("endTime", cal.getTimeInMillis()+60*60*1000);
intent.putExtra("title", "Giranice");
intent.putExtra("description", "Concierto Pop-Rock: Giranice (Gipuzkoa)");
intent.putExtra("eventLocation", "Bilborock");
startActivity(intent);
`