Search code examples
c#winformsaxacropdf

How can I get number of pages in a pdf file in AxAcroPdf?


I use AxAcroPdf to display PDF file with this code :

AcroPdfViewer.src = FilePath;
AcroPdfViewer.setPageMode("none");
AcroPdfViewer.setZoom(100);
AcroPdfViewer.setShowToolbar(true);

How can I get number of total pages of the PDF file in AxAcroPdf ?


Solution

  • 2018 edit: as commented below, the original answer referenced a method that is not an AxAcroPdf method. But an accepted answer cannot be deleted, so I have to leave it here.