2012年7月16日

同步服务器套接字示例

摘要: using System;using System.Net;using System.Net.Sockets;using System.Text;public class SynchronousSocketListener { // Incoming data from the client. public static string data = null; public static void StartListening() { // Data buffer for incoming data. byte[] bytes = new ... 阅读全文

posted @ 2012-07-16 16:44 I am Dylan 阅读(153) 评论(0) 推荐(0) 编辑

同步客户端套接字示例

摘要: using System;using System.Net;using System.Net.Sockets;using System.Text;public class SynchronousSocketClient { public static void StartClient() { // Data buffer for incoming data. byte[] bytes = new byte[1024]; // Connect to a remote device. try { // Establ... 阅读全文

posted @ 2012-07-16 16:39 I am Dylan 阅读(217) 评论(0) 推荐(0) 编辑

导航