Export (0) Print
Expand All
1 out of 1 rated this helpful - Rate this topic

Guid Constructor (UInt32, UInt16, UInt16, Byte, Byte, Byte, Byte, Byte, Byte, Byte, Byte)

.NET Framework 1.1

Initializes a new instance of the Guid class using the specified unsigned integers and bytes.

This constructor is not CLS-compliant. For more information about CLS compliance, see What is the Common Language Specification.

[Visual Basic]
<CLSCompliant(False)>
Public Sub New( _
   ByVal a As UInt32, _
   ByVal b As UInt16, _
   ByVal c As UInt16, _
   ByVal d As Byte, _
   ByVal e As Byte, _
   ByVal f As Byte, _
   ByVal g As Byte, _
   ByVal h As Byte, _
   ByVal i As Byte, _
   ByVal j As Byte, _
   ByVal k As Byte _
)
[C#]
[CLSCompliant(false)]
public Guid(
 uint a,
 ushort b,
 ushort c,
 byte d,
 byte e,
 byte f,
 byte g,
 byte h,
 byte i,
 byte j,
 byte k
);
[C++]
[CLSCompliant(false)]
public: Guid(
 unsigned int a,
 unsigned short b,
 unsigned short c,
 unsigned char d,
 unsigned char e,
 unsigned char f,
 unsigned char g,
 unsigned char h,
 unsigned char i,
 unsigned char j,
 unsigned char k
);
[JScript]
public
   CLSCompliant(false)
function Guid(
 a : UInt32,
 b : UInt16,
 c : UInt16,
 d : Byte,
 e : Byte,
 f : Byte,
 g : Byte,
 h : Byte,
 i : Byte,
 j : Byte,
 k : Byte
);

Parameters

a
The first 4 bytes of the GUID.
b
The next 2 bytes of the GUID.
c
The next 2 bytes of the GUID.
d
The next byte of the GUID.
e
The next byte of the GUID.
f
The next byte of the GUID.
g
The next byte of the GUID.
h
The next byte of the GUID.
i
The next byte of the GUID.
j
The next byte of the GUID.
k
The next byte of the GUID.

Remarks

Specifying the bytes in this manner avoids endianness issues.

Example

Guid(0xa,0xb,0xc,0,1,2,3,4,5,6,7) creates a Guid that corresponds to "0000000a-000b-000c-0001-020304050607".

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also

Guid Structure | Guid Members | System Namespace | Guid Constructor Overload List

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.