获取udp数据源IP 补充一下,我用的环境是visual studio 2005 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 string ServerIp="本地IP"int ServerPort=本地接收端口;IPEndPoint ipEndPoint = new IPEndPoint(ServerIP,ServerPort);udpClient.Recive(ref ipEndPoint);string remoteIp=ipEndPoint.Address;int remotePort=ipEndPoint.Port;是这意思不??? 好象是,不过我还是没调通。1、IPEndPoint ipendpoint = new IPEndPoint(ServerIP,ServerPort);错误1 与“System.Net.IPEndPoint.IPEndPoint(long, int)”最匹配的重载方法具有一些无效参数2、UdpClient.Receive(ref ipendpoint)错误3 非静态的字段、方法或属性“System.Net.Sockets.UdpClient.Receive(ref System.Net.IPEndPoint)”要求对象引用 参数格式不对?还是?用receive()可以接收到UDP的源IP和端口?我查着用ReceiveFrom()可以? 怎样让小数位四舍五入保留两位小数,即使小数位全是0也要保留两位 关于聊天室人员列表的问题???--急--在线等 初学者的无奈,非常之简单的问题 在c/s下的window窗体中怎样循环控件 请教,datagrid的headtext设置问题? Application的问题 io读写问题 此处为啥会弹窗两次,求助。。急。。在线等。。。 问个问题 谢谢了 .. webservices 调用泛型传参问题 没多少分了,请教一下 BackgroundWorker 和 ToolStripProgressBar 的使用 急,急,请教大大们关于汉字编码的问题 !
string ServerIp="本地IP"
int ServerPort=本地接收端口;IPEndPoint ipEndPoint = new IPEndPoint(ServerIP,ServerPort);
udpClient.Recive(ref ipEndPoint);string remoteIp=ipEndPoint.Address;
int remotePort=ipEndPoint.Port;是这意思不???
1、IPEndPoint ipendpoint = new IPEndPoint(ServerIP,ServerPort);
错误1 与“System.Net.IPEndPoint.IPEndPoint(long, int)”最匹配的重载方法具有一些无效参数
2、UdpClient.Receive(ref ipendpoint)
错误3 非静态的字段、方法或属性“System.Net.Sockets.UdpClient.Receive(ref System.Net.IPEndPoint)”要求对象引用
参数格式不对?还是?
用receive()可以接收到UDP的源IP和端口?我查着用ReceiveFrom()可以?