The following forum(s) are migrating to a new home on Microsoft Q&A (Preview): Developing Universal Windows apps!

Ask new questions on Microsoft Q&A (Preview).
Interact with existing posts until December 13, 2019, after which content will be closed to all new and existing posts.

Learn More

 locked
[UWP] Replacement for Reminder or Alarm class functionality RRS feed

  • Question

  • I have a custom calendar app (currently Windows Phone Silverlight) which i am in the process of converting to a Universal App. I use the Microsoft.Phone.Scheduler.Reminder class to register meeting reminders with the phone OS. This class is not available with Universal Apps. I explored using ScheduledToastNotification, but, the problem with this is that the notifications are not sticky. The notification show for a couple of seconds and dismisses itself. Is there any way i can have the notifications visible until the user explicitly dismiss using a button. Also, the snooze functionality is not available in ScheduledToastNotifications. Anything else i can use to achieve the desired functionality?
    Thursday, June 18, 2015 5:40 PM

All replies

  • Are you trying to convert windows phone silverlight app to win 10 universal apps?
    Monday, June 22, 2015 6:54 AM
  • Yes. Trying to port over my WP 8.1 Silverlight app to Win 10 universal.
    Monday, June 22, 2015 1:14 PM
  • Hi RadheshamShah,

    >> Is there any way i can have the notifications visible until the user explicitly dismiss using a button.

    Basically the user experience is the first priority, like the normal alarm application, if there is no user action, system will consider user is not around the device, and it will dismiss automatically, otherwise from the battery thinking, more power will be used for playing sounds and from the user sider thinking, continue playing the sounds is useless if the user is not nearby.

    >> Also, the snooze functionality is not available in ScheduledToastNotifications

    Base on my understanding, we can have commands for toast, by assign a Snooze command we can let the toast behavior like so, see the "setting the snooze" section from this blog: https://msdn.microsoft.com/en-us/magazine/dn451440.aspx?f=255&MSPPError=-2147217396

    I copied a part of code while user click the snooze, basically it register another toast in 5 mins.

    DateTime scheduledTime = DateTime.Now.AddMinutes(1);
    TimeSpan snoozeInterval = TimeSpan.FromMinutes(5);
    var scheduledToast = new ScheduledToastNotification(
      content, scheduledTime, snoozeInterval, 0);

    --James


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Wednesday, July 8, 2015 5:00 AM