IPAddress Constructor (Byte[])
[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]
Initializes a new instance of the IPAddress class with the address specified as a Byte array.
Namespace: System.Net
Assembly: System (in System.dll)
Syntax
'Declaration
Public Sub New ( _
newAddressBytes As Byte() _
)
public IPAddress(
byte[] newAddressBytes
)
public:
IPAddress(
array<unsigned char>^ newAddressBytes
)
new :
newAddressBytes:byte[] -> IPAddress
public function IPAddress(
newAddressBytes : byte[]
)
Parameters
- newAddressBytes
Type: array<System. . :: . .Byte> [] () [] []
The byte array value of the IP address.
Remarks
The IPAddress is created with the Address property set to newAddressBytes.
If the length of newAddressBytes is 4, IPAddress(array<Byte>[]()[][]) constructs an IPv4 address; otherwise, an IPv6 address with a scope of 0 is constructed.
The Byte array is assumed to be in network byte order with the most significant byte first in index position 0.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see dd66cd4c-b087-415f-9c3e-94e3a1835f74.