Skip to content
全新发布

PDF SDK 与 AI 文档处理

在 GitHub 获取完整的私有化部署SDK 包及 AI 智能文档处理能力,一键部署,快速构建您的文档处理工作流。

删除表单域

由于表单继承自注释类,所以删除表单域和删除注释的方法一致。

删除表单域的步骤如下:

  1. 从 CPDFDocument 中获取想要删除表单的页面对象。
  2. 删除表单域。

以下是删除指定文档中第一个注释的示例代码:

java
CPDFDocument document = new CPDFDocument();
document.open(pdfPath);
CPDFPage page = document.pageAtIndex(0);

List<CPDFAnnotation> annotationList = page.getAnnotations();
annotationList.remove(0);