jjzjj

predicateForEventsWithStartDate

全部标签

iphone - predicateForEventsWithStartDate 不起作用

我正在尝试从日历中获取事件,并且我正在使用此方法进行操作:predicateForEventsWithStartDate:endDate:calendars:但如果我创建这样的开始日期:NSString*str=@"3/15/19809:15PM";NSDateFormatter*formatter=[[NSDateFormatteralloc]init];[formattersetDateFormat:@"MM/dd/yyyyhh:mma"];NSTimeZone*gmt=[NSTimeZonetimeZoneWithAbbreviation:@"GMT"];[formatterse

iPhone 'Event Kit' - 如何为提取指定额外的搜索过滤器(超出开始/结束日期)?

关于iPhone“事件工具包”:除了doco中提到的开始和结束日期的有限选项之外,我如何为获取日历项目指定额外的搜索过滤器(perdocohere)?(例如,所有发生在星期一的事件,或标题与xxx匹配的事件)或者,除了predicateForEventsWithStartDate:endDate:calendars:中提供的功能之外,是否没有此类功能?,因此您需要引入所有事件,然后自己遍历它们? 最佳答案 文档对您的问题有明确的回答。请参阅eventsMatchingPredicate:方法的注释:predicateThesearc