Open ffbboy30 opened 4 months ago
It would have been much easier if you would have used the template as intended. You sent a ZIP file without code and without .SLN file.
PDFsharp only find 1 page. Further investigation pending.
Sorry here is the full template Full template.zip
Use the PDFsharp-gdi solution Thanks
Please note that this is not a "simple PDF".
When opened with Google Chrome, there is only a single page. That's the only regular page in the PDF and that's the page that PDFsharp also finds. When opened with Adobe Reader, there are 14 pages. When opened with Firefox, there are 24 pages. Opera and SumatraPDF only find one page.
Thanks to take time to answer. So, Is there a solution to get the good number of page 14 with pdfsharp because my application use the pdfsharp api.
Thanks
AIUI Adobe Reader creates the 14 pages "on the fly" from meta data included in the PDF and Firefox creates 24 pages from the same meta data.
PDFsharp does not have the capabilities to render those pages "on the fly". I did not check if you can easily access the meta data using PDFsharp.
Yesterday , I've tested with the adobe API and it found only 1 page too. Is it possible to read this metadata directly and bypass pdfsharp only for the number of pages ?
Hello, PDFsharp-gdi.zip
The problem is simple the nNbpages is 1 instead of 14
Here is my code from the issue template The code is quite simple
var pdfDocument = PdfReader.Open("CE EMR 8029635 - TCE-121190056.pdf"); int NbPages = pdfDocument.Pages.Count; Console.WriteLine(NbPages.ToString());
I put the pdf file in the debug directory
Thanks for your help