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!

BinaryReader.ReadBytes

Reads count bytes from the current stream into a byte array, and advances the current position by count bytes.

[Visual Basic]
Overridable Public Function ReadBytes( _
   ByVal count As Integer _
) As Byte ()
[C#]
public virtual byte[] ReadBytes(
   int count
);
[C++]
public: virtual unsigned char* ReadBytes(
   int count
) [];
[JScript]
public function ReadBytes(
   count : int
) : Byte[];

Parameters

count
The number of bytes to read.

Return Value

A byte array containing data read from the underlying stream. This may be less than the number of bytes requested if the end of the stream is reached.

Exceptions

Exception Type Condition
EndOfStreamException The end of the stream has been reached.
IOException An I/O error occurs.
ArgumentOutOfRangeException count is negative.

See Also

BinaryReader Class | BinaryReader Members | System.IO Namespace