简体   繁体   中英

Windows phone 7 toast notification

in toast message in windows phone 7, when clicking on that message the application opens thats fine,

i just want to navigate to specific page when the toast message is clicked,

is there any way to do it?

both in 7 and mango update???

or

in http://samidipbasu.com/2011/06/14/push-notification-payloads/ in this link when we read for toast notification, we have an extra parameter called wp:Param in xml format to send. How they were sending this wp:Param data in windows 7.0(before mango update). Any idea??

Support for navigating to a particular page is supported in Mango. Below is an example that does not require an HTTP channel, but must be executed by a background agent (not the application itself):

var toast = new ShellToast
{
    Title = "Title",
    Content = "Toast content",
    NavigationUri = new Uri("/SomeOtherView.xaml", UriKind.Relative)
};

toast.Show();

NOTE: The NavigationUri functionality is also supported by toast sent via HTTP push notifications

all the info you need to know about push notifications is here

@curiosity.. Toast & Tile payloads are pre-defined so that the OS can process these bits coming from MPNS after your app registers shellToast/shellTile. The extra parameters in the payloads are supposed to supported starting with Mango. As your app's first page (or whichever XAML page is in the URL) launches from the deep-toast, the developer should be able to listen in on the OnNavigatedTo() event to do something special with the params in the incoming URL (query string). Please see some later posts on my blog for examples & let me know if it helps.

Thanks!

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM