Few doubts related Windows push Notification service in WP Universal application

浪尽此生 提交于 2019-12-12 06:12:36

问题


I am a Windows Phone application developer. In my application I implemented push notification services using WNS . I have few doubts/questions regarding this. Please clarify

  1. How can we disable push notification for a specific application ? Can we prevent it from application side ? Or handle it from server side?

  2. If I un install my application and the server is still sending you the push notifications. Will it receive in to phone?

  3. Is that necessary to ask user permission before registering push notification channel ?

  4. Can we get notifications history of notifications received on my phone and not attended? Is there any api for that ?

Thanks


回答1:


For general WNS information see: https://msdn.microsoft.com/en-us/library/windows/apps/hh913756.aspx

For your questions:

1.How can we disable push notification for a specific application ? Can we prevent it from application side ? Or handle it from server side?

From the application you can unregister your channelUri: https://msdn.microsoft.com/en-us/library/microsoft.windowsazure.messaging.notificationhub.unregisterallasync(v=azure.10).aspx

2.If I un install my application and the server is still sending you the push notifications. Will it receive in to phone?

Not it should not receive any more push notifications

3.Is that necessary to ask user permission before registering push notification channel ?

Yes

4.Can we get notifications history of notifications received on my phone and not attended? Is there any api for that ?

You can use the classes in Windows.UI.NOtifications namespace to manage your applciations notifications on the client:

https://msdn.microsoft.com/en-us/library/windows/apps/windows.ui.notifications.aspx

Specifically Toast Notification History:

https://msdn.microsoft.com/en-us/library/windows/apps/windows.ui.notifications.toastnotificationhistory.aspx



来源:https://stackoverflow.com/questions/29144953/few-doubts-related-windows-push-notification-service-in-wp-universal-application

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