Export (0) Print
Expand All

IPAddress.Address Property

Note: This API is now obsolete. The non-obsolete alternative is GetAddressBytes().

Gets or sets an Internet Protocol (IP) address for IPv4.

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

[ObsoleteAttribute("This property has been deprecated. It is address family dependent. Please use IPAddress.Equals method to perform comparisons. http://go.microsoft.com/fwlink/?linkid=14202")]
public long Address { get; set; }

Property Value

Type: System.Int64
An IPv4 address represented as an integer.

ExceptionCondition
SocketException

The AddressFamily property is InterNetworkV6.

This property is obsolete. Use GetAddressBytes to get the IP address as an array of bytes.

The Address property is assumed to be in network byte order.

This property can only be used to get or set an IPv4 address, since the size of the long data type is not large enough for an IPv6 address.

To convert Address to dotted-decimal notation, use the ToString method.

Silverlight

Obsolete (compiler warning) in 5
Obsolete (compiler warning) in 4
Obsolete (compiler warning) in 3

Silverlight for Windows Phone

Obsolete (compiler warning) 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:
© 2014 Microsoft