使用UDP協議發送和接收數據

首選引用如下兩個: using System.Net; using System.Net.Sockets;ip //獲取機機IP地址: IPHostEntry ihe = Dns.GetHostByName(Dns.GetHostName()); IPAddress myself = ihe.AddressList[0]; //發送消息 UdpClient udpClient = new UdpC
相關文章
相關標籤/搜索