且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

无法在Android 4.0上设置日历事件>

更新时间:2023-09-03 15:44:46

检查您创建的事件的日历ID是否指向现有的已启用日历(不仅仅是eventValues.put(Events.CALENDAR_ID,1);).尝试添加指向事件的提醒时出现了这样的异常(reminderValues.put("event_id",eventID);),该事件是与与现有日历无关的calendar_id添加的.可能需要检查一下...

Check that calendar id for event you create is pointing to existing enabled calendar (not just eventValues.put(Events.CALENDAR_ID, 1);) . I was getting such exception when trying to add reminder pointing to event (reminderValues.put("event_id", eventID);), which was added with calendar_id not associated with existing calendar. There is probably some check for it...