The properties of the NetworkInterface object will unravel a rich set of information regarding network configuration and network statistics.
here is Sample Code:
using System.Net.NetworkInformation;
if(NetworkInterface.GetIsNetworkAvailable()){
NetworkInterface[] nInterface = NetworkInterface.GetAllNetworkInterfaces();
foreach(NetworkInterface ni in nInterface ){
string NetworkName = ni.Name;
}
}
hope it will helps you.
No comments:
Post a Comment