SyntaxFix
Write A Post
Hire A Developer
Questions
In .NET 4, you can use Stream.CopyTo to copy a stream, instead of the home-brew methods listed in the other answers.
MemoryStream _ms; public MyClass(Stream sourceStream) _ms = new MemoryStream(); sourceStream.CopyTo(_ms); }