Export (0) Print
Expand All

IPAddress.IsLoopback Method

Indicates whether the specified IP address is the loopback address.

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

'Declaration
Public Shared Function IsLoopback ( _
	address As IPAddress _
) As Boolean

Parameters

address
Type: System.Net.IPAddress
An IP address.

Return Value

Type: System.Boolean
true if address is the loopback address; otherwise, false.

ExceptionCondition
ArgumentNullException

The address parameter is Nothing.

The IsLoopback method compares address to Loopback when the AddressFamily property is InterNetworkV6 and returns true if the two IPv6 addresses are the same.

In the case of IPv4, that the IsLoopback method returns true for any IP address of the form 127.X.Y.Z (where X, Y, and Z are in the range 0-255), not just Loopback (127.0.0.1).

Silverlight

Supported in: 5, 4, 3

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.

Community Additions

ADD
Show:
© 2015 Microsoft