周期性活动Android的Google日历提供商例外 [英] Android Calendar Provider exception on recurring events
问题描述
我尝试利用CalendarContract内容提供商:的http://developer.android.com/reference/android/provider/CalendarContract.Events.html
I try to utilize the CalendarContract content provider: http://developer.android.com/reference/android/provider/CalendarContract.Events.html
我只能似乎无法找到关于周期性活动的异常事情。结果
<一href=\"http://developer.android.com/reference/android/provider/CalendarContract.Instances.html#CONTENT_URI\"相对=nofollow>我用实例URI查询。结果
我加了(上calendar.google.com)的事件,并使其每天重复。现在我改变的情况下,一次一个内容提供给了我异常正确:
I only can't seem to find anything regarding exception on recurring events.
I use the Instances URI to query.
I added an event (on calendar.google.com) and made it repeat every day. Now I changed one of the instances' time and the content provider gives me the exception correctly:
// Original event instance:
eventID: 320
instanceID: 651
startdate: Wed Mar 13 09:30:00 CET 2013
rrule: FREQ=WEEKLY;BYDAY=MO,TU,WE,TH,FR
original_event_id: null
exrule: null
exdate: null
// Exception event instance:
eventID: 333
instanceID: 888
startdate: Mon Mar 18 15:00:00 CET 2013
rrule: null
original_event_id: 320
exrule: null
exdate: null
正如你可以看到原来的事件上面没有 exrule
和 exdate
,但仍显示正确的异常事件(不重叠的原始事件实例)
As you can see above the original event has no exrule
and exdate
but the exception event is still shown correctly (not overlapping the original event instance)
现在,这里是我的问题:我想一个例外添加到重复事件自己。但我不知道我需要什么字段来填充和如何工作的。由于上面的例子是没有帮助的。
Now here comes my question: I want to add an exception to a recurring event myself. But I don't know what fields I need to fill and how this works. Since the example above isn't helpful at all.
推荐答案
我是有点过于草率发布了这个问题。
插入事件的 CalendarContract.Events.CONTENT_EXCEPTION_URI
将处理这一切...
I was a bit too hasty posting this question.
Inserting events to the CalendarContract.Events.CONTENT_EXCEPTION_URI
will handle all of this ...
这篇关于周期性活动Android的Google日历提供商例外的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!