共用方式為


UIApplication.CancelLocalNotification(UILocalNotification) 方法

定義

取消本機通知。

[Foundation.Export("cancelLocalNotification:")]
[ObjCRuntime.Deprecated(ObjCRuntime.PlatformName.iOS, 10, 0, ObjCRuntime.PlatformArchitecture.None, "Use 'UNUserNotificationCenter.RemovePendingNotificationRequests' instead.")]
[ObjCRuntime.Unavailable(ObjCRuntime.PlatformName.TvOS, ObjCRuntime.PlatformArchitecture.All, null)]
public virtual void CancelLocalNotification(UIKit.UILocalNotification notification);
abstract member CancelLocalNotification : UIKit.UILocalNotification -> unit
override this.CancelLocalNotification : UIKit.UILocalNotification -> unit

參數

notification
UILocalNotification

取消的本機通知。

屬性

備註

如果目前顯示通知,則會將其移除;如果未顯示,則會卸載已排入佇列的通知。

適用於