TCP服务器接受来自Windows Phone的连接

编程入门 行业动态 更新时间:2024-10-25 06:30:29
本文介绍了TCP服务器接受来自Windows Phone的连接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我已经按照此链接创建了适用于Windows Phone的客户端应用,该应用将连接到TCP服务器> www.google/url?sa=t&rct=j&q=&esrc=s&source=web&cd=3&cad=rja&sqi=2&ved=0CEQQFjAC&url= HTTP%3A%2F%2Fmsdn.microsoft%2Fen-我们%2Flibrary%2Fwindowsphone%2Fdevelop%2Fhh202858(v%的3Dvs.105)的.aspx&安培; EI = 82lLUeLpFoiIrAff7IHgAQ&安培; USG = AFQjCNGm_J9H10KucArVkkgEX2l4I2Oxww&安培; SIG2 = 9TK79y_k26tdT2qBYSMKfQ&安培; BVM = bv.44158598 ,d.bmk

i have followed this link to create a client app for windows phone which will connect to a tcp server> www.google/url?sa=t&rct=j&q=&esrc=s&source=web&cd=3&cad=rja&sqi=2&ved=0CEQQFjAC&url=http%3A%2F%2Fmsdn.microsoft%2Fen-us%2Flibrary%2Fwindowsphone%2Fdevelop%2Fhh202858(v%3Dvs.105).aspx&ei=82lLUeLpFoiIrAff7IHgAQ&usg=AFQjCNGm_J9H10KucArVkkgEX2l4I2Oxww&sig2=9TK79y_k26tdT2qBYSMKfQ&bvm=bv.44158598,d.bmk

现在我想用C#编写一个TCP服务器以从Windows Phone应用程序接收此连接,该怎么做?

now i want to write a tcp server with c# to receive this connection from windows phone app,,how to do it?

推荐答案

我刚刚在我们的博客中发布了示例代码:

I just posted sample code in our blog:

Windows Phone 8中的数据报套接字通信

它演示了链接的两端,并通过WiFi连接了两个电话.

It demonstrates both sides of the link, hooking two phones up via WiFi.

您引用的链接使用System.Net.Sockets(WP 7.1).

The link you reference uses System.Net.Sockets (WP 7.1).

对于WP 8.0应用程序,建议使用Windows.Networking.Sockets.您需要用它来编写服务器端连接.

For WP 8.0 apps, Windows.Networking.Sockets is recommended; you need it for writing a server-side connection.

希望这会有所帮助, 标记

Hope this helps, Mark

更多推荐

TCP服务器接受来自Windows Phone的连接

本文发布于:2023-10-15 00:53:20,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1492756.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:服务器   TCP   Phone   Windows

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!