In my previous entry I wrote about how .net streams don’t have a built in way to copy from one stream to another.
I also said “the function is easy enough to implement (there is even an example buried in the help file, if you can but find it)”.
Someone pointed out to me that it was unhelpful to not then go on and point out how to find it.
So, straight from the documentation for Stream.Write, here is the code:
While we’re here - notice the subtle bug in the second line, which really should be using the constant:
Comments
blog comments powered by Disqus