-api-id | -api-type | -api-device-family-note |
---|---|---|
M:Windows.UI.Notifications.ToastNotifier.AddToSchedule(Windows.UI.Notifications.ScheduledToastNotification) |
winrt method |
xbox |
Adds a ScheduledToastNotification for later display by Windows.
Important
This method is only supported in applications which use WinRT as their default application framework.
The scheduled toast notification, which includes its content and timing instructions.
This method passes the toast notification to the schedule but doesn't specify the time the toast should display. That information is included in the ScheduledToastNotification.
Be sure to handle these exceptions when calling AddToSchedule:
- Exception:
System.Exception: 'Not enough quota is available to process this command. (Exception from HRESULT: 0x80070718)'
- Possible cause: You've exceeded the maximum allowed number of scheduled notifications.
Fix: ToastNotifier.addToSchedule will fail if you attempt to schedule more than 4096 notifications. Reduce your number of scheduled notifications.
- Possible cause: Your notification is scheduled for a time in the past relative to the current system clock time.
Fix: Make sure that the scheduled notification time specified in your ScheduledToastNotification is in the future. Examine the system clock time.