IPGlobalStatistics.NumberOfIPAddresses Property

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Gets the number of Internet Protocol (IP) addresses assigned to the local computer.

Namespace:   System.Net.NetworkInformation
Assembly:  System (in System.dll)

public abstract int NumberOfIPAddresses { get; }

Property Value

Type: System.Int32

An Int64 value that indicates the number of IP addresses assigned to the address family (Internet Protocol version 4 or Internet Protocol version 6) described by this object.

The data returned by this property includes addresses of pseudo network interfaces such as tunnels.

If this instance was obtained by calling GetIPv4GlobalStatistics, this property returns the number of IPv4 addresses assigned to the local computer. Similarly, if this instance was obtained by calling GetIPv6GlobalStatistics, this property returns the number of IPv6 addresses assigned to the local computer.

.NET Framework
Available since 2.0
Return to top
Show: