LONG PageCount { get; } |
PageCount returns the total number of pages in the PDF document.
Equivalent in new interface: IPDFDocument4::GetPageCount.
{ PDF object is supposed to be created } PDF.BeginDoc; PDF.NewPage; PDF.NewPage; for i := 0 to PDF.PageCount-1 do begin PDF.SetCurrentPage(i); PDF.PDFPAGE_SetActiveFont('Verdana', False, False, False, False, 8.0, 0); PDF.PDFPAGE_TextOut(100, 100, 0.0, 'Page ' + IntToStr(i + 1)); end; PDF.EndDoc;
// PDF object is supposed to be created PDF->BeginDoc(); PDF->NewPage(); PDF->NewPage(); for (LONG i = 0; i < PDF.PageCount; i++) { PDF->SetCurrentPage(i); PDF->PDFPAGE_SetActiveFont("Verdana", FALSE, FALSE, FALSE, FALSE, 8.0, 0); CString str; str->Format("Page %d", i + 1); PDF->PDFPAGE_TextOut(100, 100, 0.0, str); } PDF.EndDoc();
// PDF object is supposed to be created PDF.BeginDoc(); PDF.NewPage(); PDF.NewPage(); for (long i = 0; i < PDF.PageCount; i++) { PDF.SetCurrentPage(i); PDF.PDFPAGE_SetActiveFont("Verdana", FALSE, FALSE, FALSE, FALSE, 8, 0); string str = "Page " + (i + 1).ToString(); PDF.PDFPAGE_TextOut(100, 100, 0, str); } PDF.EndDoc();
' PDF object is supposed to be created PDF.BeginDoc PDF.NewPage PDF.NewPage for i=0 to PDF.PageCount-1 PDF.SetCurrentPage i PDF.PDFPAGE_SetActiveFont "Verdana", FALSE, FALSE, FALSE, FALSE, 8, 0 PDF.PDFPAGE_TextOut 100, 100, 0, "Page " & i + 1 next PDF.EndDoc