Spire.PDF is a professional PDF library applied to creating, writing, editing, handling and reading PDF files without any external dependencies. Get free and professional technical support for Spire.PDF for .NET, Java, Android, C++, Python.
Wed Apr 10, 2019 10:55 pm
I'd like to flatten the whole pdf or the individual fields but currently i dont know how.
thanks in advance
-

ososoos
-
- Posts: 1
- Joined: Wed Apr 10, 2019 9:59 pm
Thu Apr 11, 2019 7:57 am
Hi,
Thank you for your inquiry.
Our
Spire.PDF for Java provides method to flatten PDF form fields. Please refer to the following code. If there is any question, please feel free to write back.
- Code: Select all
String inputFile = "Test.pdf";
String outputFile = "flattenFormField.pdf";
PdfDocument doc = new PdfDocument();
doc.loadFromFile(inputFile);
//Flatten form fields
doc.getForm().isFlatten(true);
doc.saveToFile(outputFile);
doc.close();
Sincerely,
Nancy
E-iceblue support team
-


nancy.yang
-
- Posts: 184
- Joined: Wed Apr 03, 2019 2:33 am
Mon Apr 15, 2019 9:42 am
Hi,
How is your issue now? Could you please give us some feedback at your convenience? Thanks in advance.
Sincerely,
Nancy
E-iceblue support team
-


nancy.yang
-
- Posts: 184
- Joined: Wed Apr 03, 2019 2:33 am