Breyta

Deila með


IPAddress.None Field

Definition

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

public: static initonly System::Net::IPAddress ^ None;
public static readonly System.Net.IPAddress None;
 staticval mutable None : System.Net.IPAddress
Public Shared ReadOnly None As IPAddress 

Field Value

Examples

The following example uses the None property to indicate that no network interface should be used.

int main()
{
   
   // Gets the IP address indicating that no network interface should be used
   // and converts it to a String*.
   String^ address = IPAddress::None->ToString();
   Console::WriteLine( "IP address : {0}", address );
}
public static void Main()
{
   // Gets the IP address indicating that no network interface should be used
   // and converts it to a string.
   string address = IPAddress.None.ToString();
   Console.WriteLine("IP address : " + address);
}
Public Shared Sub Main()

    ' 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()
    Console.WriteLine(("IP address : " + address))
End Sub

Remarks

The Socket.Bind method uses the None field to indicate that a Socket must not listen for client activity. The None field is equivalent to 255.255.255.255 in dotted-quad notation.

Applies to