public override void CancelAllLocalNotifications ()
{
UIApplication.SharedApplication.InvokeOnMainThread (delegate {
UILocalNotification[] localNotifications = UIApplication.SharedApplication.ScheduledLocalNotifications;
if(localNotifications==null || localNotifications.Length<=0) {
SystemLogger.Log(SystemLogger.Module.PLATFORM,"No scheduled notifications found to cancel");
} else {
foreach(UILocalNotification notification in localNotifications) {
SystemLogger.Log(SystemLogger.Module.PLATFORM,
"Cancelling local notification scheduled at: " + notification.FireDate.ToString()
+ ", with a repeat interval of: " + notification.RepeatInterval);
}
}
UIApplication.SharedApplication.CancelAllLocalNotifications();
});
}