UIlocalNotification 中的下一个触发日期
大家好
我创建了一个 UILocalNotification...&当我打印它时,
NSLog(@"Notification %@",self.notification)
它给出
Notification <UIConcreteLocalNotification: 0x6f45440>
{fire date = 2010-10-22 00:09:00 -0700, time zone = America/Vancouver (PDT) offset -25200
(Daylight), repeat interval = 64, **next fire date** = 2010-10-22 00:10:00 -0700}
但我想访问此通知的下一个触发日期我怎样才能获得这个值?
请为此提供任何帮助。
Hi All
I have created a UILocalNotification....& when i print it
NSLog(@"Notification %@",self.notification)
it gives
Notification <UIConcreteLocalNotification: 0x6f45440>
{fire date = 2010-10-22 00:09:00 -0700, time zone = America/Vancouver (PDT) offset -25200
(Daylight), repeat interval = 64, **next fire date** = 2010-10-22 00:10:00 -0700}
But I want to access the next fire date of this Notification how can i get this value?
Please any help for this.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
UILocalNotification
有一个 fireDate 您可以使用的属性。UILocalNotification
has a fireDate property that you can use.您无法直接将其作为属性访问,因为它是根据 fireDate 和 RepeatInterval 计算的。
这是您问题的答案
如何抓取来自 UILocalNotification 对象的下一个触发日期
You can't access it directly as a property, because it is calculated based on fireDate and repeatInterval.
Here is the answer to your question
How to grab the NEXT fire date from a UILocalNotification object
只需使用:
Just use: