Distinct normal launch with push notification Windows Phone 7

元气小坏坏 提交于 2019-12-14 02:25:37

问题


hi I have been developing an App for Windows Phone 7 with daily update when start and push notification enable. so far I use 2 types of push notification at the same time ( toast and tile ). since my App need a long time update. so I will have to distinct between normal start ( will update ) and start from push notification ( no update will be allowed ). Now I can distinct for the toast with query string. but when start from tile I can't because I donno how to get the count from the tile of my App.

so the question is "How can I get the count from tile notification ?"


回答1:


You can query your tile data when the app is launching and look at the Count property, if > 0 it's a launch after notification.

To get your application tile:

var tileToFind = ShellTile.ActiveTiles.First();
int count = tileToFind.Count;


来源:https://stackoverflow.com/questions/7977836/distinct-normal-launch-with-push-notification-windows-phone-7

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!