草庐IT

repeatCalendar

全部标签

ios - UILocalNotification 设置 repeatCalendar

我是NSCalander、NSdates和NSDateComponents的新手基本上我有一个本地通知,我想根据用户的选择重复触发日期,比如说只在周日和周一。我们应该为UILocalNotification使用repeatCalendar属性,但我不知道如何设置它。所以任何人都可以用简单的代码行帮助我吗?谢谢 最佳答案 有一个代码片段可以将UILocalNotification设置为在每周日20:00触发。NSCalendar*calendar=[[NSCalendaralloc]initWithCalendarIdentifier