Error loading default propertIEs for object x-apple-eventkit:///Alarm/p252 from daemon: Error Domain=EKCADErrorDomain Code=1010 "(null)"Error loading to-one relation originalAlarm from daemon: Error Domain=EKCADErrorDomain Code=1010 "(null)"
我的代码:
NSDateFormatter *dateFromater = [[NSDateFormatter alloc]init];NSTimeZone * timeZone = [NSTimeZone localTimeZone];[dateFromater setTimeZone:timeZone];[dateFromater setDateFormat:@"Y-MM-d'T'HH:mm:ss'.000Z'"];EKEventStore* evStore = [[EKEventStore alloc]init];[evStore requestAccesstoEntityType:EKEntityTypeEvent completion:^(BOol granted,NSError * _Nullable error) { EKEvent * event = [EKEvent eventWithEventStore:evStore]; event.location=[dictionry valueForKey:@"location"]; event.Title = [dictionry valueForKey:@"eventname"]; event.notes = [dictionry valueForKey:@"description"]; NSDateFormatter *formatter = [[NSDateFormatter alloc] init]; [formatter setDateFormat:@"yyyy-MM-dd'T'HH:mm:ss.SSS'Z'"]; Nsstring *str = [formatter stringFromDate:[NSDate date]]; event.startDate = [formatter dateFromString:[dictionry valueForKey:@"eventDate"]]; //[dictionry valueForKey:@"eventDate"]; event.endDate = [event.startDate dateByAddingTimeInterval:60]; EKAlarm *ekAlarm = [EKAlarm alarmWithrelativeOffset:-60]; [event addAlarm:ekAlarm]; RLMResults *object = [RealmUser allObjects]; self.user= [object firstObject]; event.calendar = [evStore calendarWithIDentifIEr:self.user.calendarIDentifIEr]; EKRecurrenceEnd * end = [EKRecurrenceEnd recurrenceEnDWithEndDate:[NSDate dateWithTimeIntervalSince1970:[[dictionry objectForKey:@"endDateForReps"]intValue]]]; EKRecurrenceFrequency freq; Nsstring *timeUntilForReps =[dictionry objectForKey:@"timeUnitForReps"] ; if ([timeUntilForReps isEqualToString:@"week"]) freq = EKRecurrenceFrequencyWeekly; else if ([timeUntilForReps isEqualToString:@"day"]) freq = EKRecurrenceFrequencyDaily; else if ([timeUntilForReps isEqualToString:@"year"]) freq = EKRecurrenceFrequencyYearly; else if ([timeUntilForReps isEqualToString:@"mounth"]) freq = EKRecurrenceFrequencyMonthly; NSInteger timeInterval = [[dictionry valueForKey:@"repeatInterval"] integerValue]; EKRecurrenceRule * rule = [[EKRecurrenceRule alloc]initRecurrenceWithFrequency:freq interval:timeInterval end:end]; [event setRecurrenceRules:@[rule]]; [evStore saveEvent:event span:EKSpanThisEvent commit:YES error:&error]; if (error) NSLog(@"error");}];@H_403_20@解决方法 我在阅读日历活动时遇到了这组错误:
Error loading default propertIEs for object x-apple-eventkit:///Location/p1 from daemon: Error Domain=EKCADErrorDomain Code=1013 "(null)"Error loading string Title from daemon: Error Domain=EKCADErrorDomain Code=1013 "(null)"Error loading default propertIEs for object x-apple-eventkit:///Location/p1 from daemon: Error Domain=EKCADErrorDomain Code=1013 "(null)"Error loading string address from daemon: Error Domain=EKCADErrorDomain Code=1013 "(null)"
使用NSLog,我确定在处理一个特定事件时发生了消息.
基于这些消息,我想记录事件的位置值并将其与其他返回的事件进行比较.但值似乎只是一个空字符串,所有其他事件也有空字符串.
进一步检查实际的日历,我发现这个特定的事件在其位置字段中有一个空格或一些不可见的字符(删除x显示,但似乎没有字符存在).我通过按x删除了不可见的字符:没有更多的消息!
在这种情况下,不是我的代码导致问题.但是,错误消息的提示使我得到了解决方案.如果我一直在构建事件,我会查看我的代码来创建Location属性的数据.
摘要:
>请注意与错误相关的属性.>请注意属性错误后的其他错误消息.>将您的故障排除重点放在该领域.
总结以上是内存溢出为你收集整理的ios – 加载对象x-apple-eventkit的默认属性时出错全部内容,希望文章能够帮你解决ios – 加载对象x-apple-eventkit的默认属性时出错所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)