O'Reilly logo

Windows® Phone 8 Unleashed by Daniel Vaughan

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Receiving a Toast Notification from Within an Application

The HttpNotificationChannel.ShellToastNotificationReceived event is used to receive toast notifications within your app, like so:

channel.ShellToastNotificationReceived +=          channel_ShellToastNotificationReceived;

Note

Toast notifications are displayed only when your app is not running in the foreground. If your app is running in the foreground, the toast notification can still be received and handled in code.

When the ShellToastNotificationReceived event is raised, the handler receives a NotificationEventArgs object from which the relevant toast notification fields can be extracted, as shown:

void channel_ShellToastNotificationReceived( ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required