Skip to content

PDF 生成模板编辑器

开源可视化 PDF 生成引擎,支持自定义模板,并提供面向开发者的 API,灵活构建文档生成流程。

查看 GitHub

合并页面

以下是合并页面的步骤:

  1. 创建一个空白 PDF 文档。
  2. 打开包含要合并页面的 PDF 文档。
  3. 选中所有需要合并的页面,将其合并到同一个文档中。

以下是合并页面的示例代码:

C#
CPDFDocument documentforMerge = CPDFDocument.CreateDocument();

CPDFDocument document1 = CPDFDocument.InitWithFilePath("filePath");
CPDFDocument document2 = CPDFDocument.InitWithFilePath("filePath2");

documentforMerge.ImportPagesAtIndex(document1,"1-10",document.PageCount);
documentforMerge.ImportPagesAtIndex(document2,"1-10",document.PageCount);