UniqueId.TryGetGuid Method (Byte[], Int32)

 

Tries to get the value of the UniqueId as a Guid and store it in the given byte array at the specified offest.

Namespace:   System.Xml
Assembly:  System.Runtime.Serialization (in System.Runtime.Serialization.dll)

public bool TryGetGuid(
	byte[] buffer,
	int offset
)

Parameters

buffer
Type: System.Byte[]

byte array that will contain the Guid.

offset
Type: System.Int32

Position in the byte array to start inserting the Guid value.

Return Value

Type: System.Boolean

true if the value stored in this instance of UniqueId is a Guid; otherwise false.

Exception Condition
ArgumentNullException

buffer is null.

ArgumentOutOfRangeException

offset less than zero or greater than the length of the array.

ArgumentException

buffer and offset provide less than 16 valid bytes.

This method is unsafe.

Universal Windows Platform
Available since 8
.NET Framework
Available since 3.0
Portable Class Library
Supported in: portable .NET platforms
Silverlight
Available since 3.0
Windows Phone Silverlight
Available since 7.0
Windows Phone
Available since 8.1
Return to top
Show: