title: iTextSharp: "The document has no pages" when using ColumnText
body: <p>The following code throws "The document has no pages"</p>
  
  <pre><code>using (var stream = new MemoryStream())
  {
      using (var document = new Document())
      {
          document.SetPageSize(PageSize.LETTER);
  
          using (var pdfWriter = PdfWriter.GetInstance(document, stream))
          {
              document.Open();
  
              PdfContentByte pdfContentByte = pdfWriter.DirectContent;
  
              ColumnText columnText = new ColumnText(pdfContentByte);
              columnText.SetSimpleColumn(0, 0, 100, 20);
              columnText.AddElement(new Paragraph("Sample text", new Font(Font.FontFamily.HELVETICA, 20)));
              columnText.Go();
  
              document.Close();
          }
      }
  
      byte[] pdfBytes = stream.ToArray();
  
      // ...
  }
  </code></pre>
  
  <p>How am I supposed to use <code>ColumnText</code> and <code>DirectContent</code> if this is not the way to do it?</p>
  
  <p>I'm using iTextSharp 5.5.3</p>