在 Windows Phone 7 中建立推送通知
我必须在我的项目中实现推送通知。 它有发送方(Windows Phone 窗口应用程序)、WCF 服务和客户端(Windows Phone 应用程序)。
如何替换发件人并使用我的网址发送和接收来自客户端的通知?
我希望发送者是模拟器本身中的某个应用程序,它与客户端并行运行并将数据连续推送到客户端。
如何开发这样的应用程序。
任何人都可以告诉
i have to implement push notification in my project.
It has sender(windows phone window application),wcf service and client(windows phone applcation).
How can i replace the sender and use my url to send and recieve notification from client?
i want sender to be some application in emulator itself that run parallely with the client and push data continously to the client.
how to develop such application
can anyone tell the way.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
听起来好像您正在寻找使用两个 WP7 应用程序通过推送通知功能来相互发送消息。这是正确的吗?
据我了解,您仍然需要每个设备使用订阅成功时发回的唯一 URI 来订阅推送通知服务(MS 托管)。看起来 SL3/4 可以创建 HttpWebRequest 对象,因此应该能够制定正确的包来发送,但是,我认为困难在于如何获取要将帖子发送到的设备的 URI。通常情况下,帖子会发送给订阅者,订阅者知道其在 URI 上,因为它是在订阅阶段返回的。
我的 WCF 托管代码仅在 WCF 知道设备的 URI 时才起作用,该 URI 在调用 WCF 方法时发送:
我知道这是一个 TileNotification,但原理是相同的。
据我所知,Mango(WP7.1 和 SL4)将支持套接字 这可能是您的设备进行通信的更合适的方式!
祝你好运,
杰森。
It sounds as though you are looking to use two WP7 apps to send messages back and forth to one another using the push notification functionality. Is that correct?
My understanding it that you will still require a each device to subscribe to a push notification service (MS hosted) using the unique URI sent back when the subscription is successful. It appears that SL3/4 can create HttpWebRequest objects and therefore should be able to formulate a correct package to send, however, the difficulty as I see it will be how to obtain the URI of the device you want to send the post to. Normally the post is sent to the subscriber, which knows its on URI as it was returned during the subscribing phase.
My WCF hosted code only works if the WCF knows the URI of the device, which is sent when the WCF method is called:
I know this is a TileNotification, but the principles are the same.
I understand that Mango (WP7.1 & SL4) will support sockets and this might be a more appropriate way for your devices to communicate!
Good luck,
Jason.