Split PDF to End

Split PDF to end

The Java sample extracts all pages starting from page 2.

Steps

  1. Create a PdfFileEditor instance.
  2. Call splitToEnd with the source file, starting page number, and output file.
  3. Save the resulting PDF document.
public static void splitPdfToEnd(Path inputFile, Path outputFile) {
    PdfFileEditor pdfFileEditor = new PdfFileEditor();
    pdfFileEditor.splitToEnd(inputFile.toString(), 2, outputFile.toString());
}