Freigeben über


IPAddress.None Field

Microsoft Silverlight will reach end of support after October 2021. Learn more.

Provides an IP address that indicates that no network interface should be used. This field is read-only.

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

Syntax

'Declaration
Public Shared ReadOnly None As IPAddress
public static readonly IPAddress None

Remarks

The None field is equivalent to 255.255.255.255 in dotted-decimal notation.

Examples

The following code example displays the value of the IPv4 None address.

' This sample gets the IP address indicating that no network interface 
' should be used and converts it to a string. 
Dim address As String = IPAddress.None.ToString()
outputBlock.Text &= "IP address: "
outputBlock.Text &= address
outputBlock.Text &= vbCrLf
      // Gets the IP address indicating that no network interface should be used 
      // and converts it to a string.
      string address = IPAddress.None.ToString();
      outputBlock.Text += "IP address: ";
      outputBlock.Text += address;
      outputBlock.Text += "\n";

Version Information

Silverlight

Supported in: 5, 4, 3

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1

Platforms

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