NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

Buffer.GetByte

Retrieves the byte at the specified location in the array.

[Visual Basic]
Public Shared Function GetByte( _
   ByVal array As Array, _
   ByVal index As Integer _
) As Byte
[C#]
public static byte GetByte(
   Array array,
   int index
);
[C++]
public: static unsigned char GetByte(
   Array* array,
   int index
);
[JScript]
public static function GetByte(
   array : Array,
   index : int
) : Byte;

Parameters

array
The array that contains the bytes.
index
The location in array of the bytes to get.

Return Value

Returns the index byte in the array.

Exceptions

Exception Type Condition
ArgumentException If the array is not a primitive.
ArgumentNullException If the array is null.
ArgumentOutOfRangeException If the index is negative or greater than the array length.

Remarks

The GetByte method gets a particular byte out of the array. The array must be an array of primitives. This essentially does the following:

return ((byte*)array) + index

See Also

Buffer Class | Buffer Members | System Namespace