0

我一直在寻找一种方法来编写一个方法,我可以调用我的应用程序中的一个按钮来删除从服务器端收到的所有通知,并从通知中心iOS中删除所有通知,我尝试了所有建议解决方案:iOS示例代码清除通知中心的应用程序通知?

iOS remove notification from notification center

iOS application: how to clear notifications?

iOS application: how to clear notifications?

是没有什么办法,我能得到办理通知C内的通知进入并做明确或删除

问候,

回答

0

感谢所有,

我已经尝试如此多的代码后,解决了我的问题,我叫上一个按钮的方法和它在这个片段的工作:

[[UIApplication sharedApplication] setApplicationIconBadgeNumber: 1]; 
[[UIApplication sharedApplication] setApplicationIconBadgeNumber: 0]; 

Regards,

相关问题