title: iTextSharp for some reason is not writing to MemoryStream
body: <p>My code </p>
  
  <pre><code> using (iTextSharp.text.Document document = new iTextSharp.text.Document(iTextSharp.text.PageSize.A4.Rotate()))
              {
                  MemoryStream memoryStream = new MemoryStream();
  
                  PdfWriter.GetInstance(document, memoryStream);
                  document.Open();
                  List&lt;IElement&gt; objects = HTMLWorker.ParseToList(new StringReader(html), null);
                  foreach (IElement element in objects)
                  {
                      if (element.Chunks.Select(x =&gt; x.Content).Contains("page_break_here")) document.Add(Chunk.NEXTPAGE);
                      else document.Add(element);
                  }
  
  
                  byte[] docArray = memoryStream.ToArray();
  }
  </code></pre>
  
  <p>memoryStream.Length is 16 </p>
  
  <p>and when I try this:</p>
  
  <pre><code>PdfWriter.GetInstance(document, new FileStream(fullPdfFileAddress, FileMode.Create));
  </code></pre>
  
  <p>it creates file just fine, but i need to write it into memoryStream.</p>