gray laptop computer showing html codes in shallow focus photography

Scheduling Notification in Windows Phone – Reminders

In Windows Phone, one can display the Scheduling Notification dialog box using

  • Alarm
  • Reminders

The Scheduling Notification displays a dialog window with the message as well as buttons to perform actions on the notifications like dismiss or postpone.

In this Blog post, I will show you how to create a simple reminder

You can create a reminder in your Application using the Reminder Class and ScheduledActionService class in Windows Phone. It is defined in the name space Microsoft.Phone.Scheduler;

The Reminder Class inherits from the ScheduledNotification which in turn inherits from the Scheduled Action

public sealed class Reminder : ScheduledNotification

public abstract class ScheduledNotification : ScheduledAction

Create an instance of the Reminder class and set the Begin Time, Expiration Time (if any), Title and Content and then add it to the ScheduledActionService.

It is also necessary to check if the reminder with the same name is already to the ScheduledActionService, If yes, then we should first remove it and add the new one .

Reminder objReminder = ScheduledActionService.Find("testreminder") as Reminder;
if (objReminder != null)
ScheduledActionService.Remove("testreminder");
objReminder = new Reminder("testreminder");
objReminder.BeginTime = DateTime.Now.AddSeconds(10);
objReminder.Title = "Article Time";
objReminder.Content = "Its time for developerpublish.com Article";             
objReminder.NavigationUri = new Uri("/test.xaml",UriKind.Relative);
ScheduledActionService.Add(objReminder);

The Reminder class also exposes an property Navigation Uri that points to the page within the Application .

Scheduling Notification in Windows Phone - Reminders
Scheduling Notification in Windows Phone – Reminders
Scheduling Notification in Windows Phone - Reminders
Scheduling Notification in Windows Phone – Reminders

Leave A Reply

Your email address will not be published. Required fields are marked *

You May Also Like

In this post, you’ll learn about the Win32 Error “0x000019E5 – ERROR_COULD_NOT_RESIZE_LOG” that you get when debugging system erors in...
In this post, you’ll learn about the error “CO_E_DBERROR 0x8004E02B” that is returned when working with COM based APIs or...
In this post, you’ll learn about the Win32 Error “0x000019D0 – ERROR_LOG_BLOCK_VERSION” that you get when debugging system erors in...