title: Reading PDF document with iTextSharp creates string with repeating first page
body: <p>I currently use iTextSharp to read in some PDF files and parse them by using the string I receive. I have encountered a strange behavior with some PDF files. When getting the string back of a for example 4 page PDF, the string is filled with the pages in the following order:</p>
  
  <p>1 2 1 3 1 4</p>
  
  <p>My code for reading the files is as follows:</p>
  
  <pre><code>using (PdfReader reader = new PdfReader(fileStream))
  {
       StringBuilder sb = new StringBuilder();
  
       ITextExtractionStrategy strategy = new SimpleTextExtractionStrategy();
       for (int page = 0; page &lt; reader.NumberOfPages; page++)
       {
           string text = PdfTextExtractor.GetTextFromPage(reader, page + 1, strategy);
           if (!string.IsNullOrWhiteSpace(text))
               sb.Append(Encoding.UTF8.GetString(Encoding.Convert(Encoding.Default, Encoding.UTF8, Encoding.Default.GetBytes(text))));
       }
  
       Debug.WriteLine(sb.ToString());
  }
  </code></pre>
  
  <p>Here is a link to a file with which this behaviour occurs:</p>
  
  <p><a href="https://onedrive.live.com/redir?resid=D9FEFF3BF45E05FD!1536&amp;authkey=!AFLRlskAvlg89yY&amp;ithint=file%2cpdf" rel="nofollow">https://onedrive.live.com/redir?resid=D9FEFF3BF45E05FD!1536&amp;authkey=!AFLRlskAvlg89yY&amp;ithint=file%2cpdf</a></p>
  
  <p>Hope you guys can help me out!</p>