获取C#中LAN连接的所有计算机的IPAddress和Computer Name。 [英] Get IPAddress and Computer Name of the all computer connected in a LAN in C#.

查看:95
本文介绍了获取C#中LAN连接的所有计算机的IPAddress和Computer Name。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试搜索代码,以获取使用C#编程在LAN中连接的所有计算机的所有IPAddress和计算机名称。我发现的所有结果都是关于检索主机IP地址和计算机名称的唯一想法。任何人都可以给我一个关于将所有IPAddress和计算机名称检索到LAN中连接的主机的想法。

I am tried of searching the code for getting the all IPAddress and Computer Name of the all computer connected in a LAN with C# programming. All the result i had found is the only the idea about retrieving Host IPAddress and Computer Name. Anyone can give me the idea about retrieving all IPAddress and Computer Name to the host which is connected in a LAN.

推荐答案




您可以从.net使用 System.Net 库,请关注以下链接:



< a href =http://www.codeproject.com/Questions/399318/How-to-Get-User-IP-address-using-csharp>如何使用c#获取用户IP地址 [ ^ ]

http://www.c-sharpcorner.com/UploadFile /mahesh/get_ip11152005064604AM/get_ip.aspx [ ^ ]

http:// msdn.microsof t.com/en-us/library/system.net.ipaddress.aspx [ ^ ]

http://www.codeguru.com/csharp/csharp/cs_network/article.php/c6041/Obtain-all-IP-addresses -of-local-machine.htm [ ^ ]



最好的问候。
Hi
You can use System.Net library from the .net please follow of these links:

How to Get User IP address using c#[^]
http://www.c-sharpcorner.com/UploadFile/mahesh/get_ip11152005064604AM/get_ip.aspx[^]
http://msdn.microsoft.com/en-us/library/system.net.ipaddress.aspx[^]
http://www.codeguru.com/csharp/csharp/cs_network/article.php/c6041/Obtain-all-IP-addresses-of-local-machine.htm[^]

Best Regards.


看到这个问题...

在Windows窗体应用程序中使用c#查找连接到LAN的计算机的主机和IP地址 [ ^ ]



这个也是......

查找连接到LAN的计算机的主机名和IP地址 [ ^ ]



嗯,这些解决方案更像是黑客攻击,工作做得更好。如果你想真正实现网络/视图的工作方式,一个人自己,这里有点信息...



Windows使用SSDP和UPnP来发现服务。 此Wiki文章 [ ^ ]是一个很好的起点。



祝你好运!
See this question...
Find host and ip address of computers connected to LAN using c# in Windows form applicatio[^]

and this one also...
Find Host Name and IP Address of Computers Connected to LAN[^]

Well, the solutions are bit more like hacks, the do the work. If you want to really implement how "net /view" works, all by yourself, here's a bit info...

Windows Uses SSDP and UPnP to discover services. This wiki article[^] is a great starting point.

Good Luck!


这篇关于获取C#中LAN连接的所有计算机的IPAddress和Computer Name。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆