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!

MemoryStream.ToArray

Writes the entire stream contents to a byte array, regardless of the Position property.

[Visual Basic]
Overridable Public Function ToArray() As Byte ()
[C#]
public virtual byte[] ToArray();
[C++]
public: virtual unsigned char* ToArray() [];
[JScript]
public function ToArray() : Byte[];

Return Value

A new byte array.

Exceptions

Exception Type Condition
ArgumentException The stream is closed.

See Also

MemoryStream Class | MemoryStream Members | System.IO Namespace