title: MemoryStream have one thread write to it and another read
body: <p>This is how I write to a stream then read from it using 1 thread:</p>
  
  <pre><code>        System.IO.MemoryStream ms = new System.IO.MemoryStream();
  
          // write to it
          ms.Write(new byte[] { 1, 2, 3, 4, 5, 6, 7 }, 0, 7);
  
          // go to the begining
          ms.Seek(0, System.IO.SeekOrigin.Begin);
  
          // now read from it
          byte[] myBuffer = new byte[7];
          ms.Read(myBuffer, 0, 7);
  </code></pre>
  
  <p><strong>Now I was wondering if it is possible to write to the memory-stream from one thread and read that stream from a separate thread.</strong></p>