NetworkInformation
The System.Net.NetworkInformation namespace enables you to gather information about network events, changes, statistics, and properties. You can also determine whether a remote host is reachable by using the System.Net.NetworkInformation::Ping class.
The System.Net.NetworkInformation::NetworkChange class enables you to determine whether the network address or availability has changed. To use this class, create an event handler to process the change, and associate it with a NetworkAddressChangedEventHandler or a NetworkAvailabilityChangedEventHandler. For more information, see How to: Detect Network Availability and Address Changes.
You can gather network statistics and properties on an interface or protocol basis. The NetworkInterface, NetworkInterfaceType, and PhysicalAddress classes give information about a particular network interface, while the IPInterfaceProperties, IPGlobalProperties, IPGlobalStatistics, TcpStatistics, and UdpStatistics classes give information about layer 3 and layer 4 packets. For more information, see How to: Get Interface and Protocol Information.
You can use the Ping class to determine whether a Remote Host is up, on the network, and reachable. For more information, see How to: Ping a Host.