XardozCom
Member
We have been chasing this for a week.
The Internet is full of half answers.
With this code modified, can we get the Adapter Name (Not Manufacture), IPv4 and Connection status?
The Internet is full of half answers.
With this code modified, can we get the Adapter Name (Not Manufacture), IPv4 and Connection status?
VB.NET:
Dim adapters As NetworkInterface() = NetworkInterface.GetAllNetworkInterfaces()
Dim adapter As NetworkInterface
For Each adapter In adapters
Dim properties As IPInterfaceProperties = adapter.GetIPProperties()
Console.WriteLine(adapter.Description)
Console.WriteLine(" DNS suffix................................. :{0}", properties.DnsSuffix)
Console.WriteLine(" DNS enabled ............................. : {0}", properties.IsDnsEnabled)
Console.WriteLine(" Dynamically configured DNS .............. : {0}", properties.IsDynamicDnsEnabled)
Console.WriteLine(properties.GetIPv4Properties())
Next adapter
For Each nic As System.Net.NetworkInformation.NetworkInterface In System.Net.NetworkInformation.NetworkInterface.GetAllNetworkInterfaces()
Console.WriteLine(nic.GetIPProperties().UnicastAddresses(0).Address)
Next