PageCount
PdfSaveOptions.PageCount property
Gets or sets the number of pages to save.
public int PageCount { get; set; }
Remarks
Default is System.Int32.MaxValue which means all pages will be rendered..
Examples
The following example shows how to render a range of pages (3 and 4) in a Microsoft Excel file to PDF.
//Open an Excel file
Workbook wb = new Workbook("Book1.xlsx");
PdfSaveOptions options = new PdfSaveOptions();
//Print only Page 3 and Page 4 in the output PDF
//Starting page index (0-based index)
options.PageIndex = 3;
//Number of pages to be printed
options.PageCount = 2;
//Save the PDF file
wb.Save("output.pdf", options);
See Also
- class PdfSaveOptions
- namespace Aspose.Cells
- assembly Aspose.Cells