getPageCount Method |
Gets the page count of the document currently being viewed in the PdfWebControl instance.
function getPageCount();
None
Type: Integer
Returns number of pages in the currently open document.This method will return a number less than 1 if no pages are found or a document is not open.
var myApi = new PdfWebControlApi("PdfWebControl1"); // where "PdfWebControl1" is the ID (ClientID) assigned to the PdfWebControl instance window.alert("This document has " + myApi.getPageCount() + " pages.");