Some test text!

Search
Hamburger Icon

UWP / Guides / Split pages

Split PDF pages in UWP

To split a PDF document into multiple pages.

PDFDoc doc = new PDFDoc(fileName);
int pageNumber = doc.GetPageCount();
for (int i = 1; i <= pageNumber; ++i)
{
    PDFDoc newDocument = new PDFDoc();
    newDocument.InsertPages(0, doc, i, i, PDFDocInsertFlag.e_none);
    await newDocument.SaveAsync(outputFileName + "_split_page_" + i + ".pdf", SDFDocSaveOptions.e_linearized);
}

Merge, Copy, Delete, and Rearrange PDF Pages
Full code sample which illustrates how to copy pages from one document to another, how to delete, and rearrange pages and how to use ImportPages().

Get the answers you need: Chat with us