PDFBox Form fill - saveIncremental does not work
I have a pdf file with some form field that I want to fill from java. Right now I'm trying to fill just one form which I am finding by its name. My code looks like this: File file = new File("c:/Testy/luxmed/Skierowanie3.pdf"); PDDocument document = PDDocument.load(file); PDDocumentCatalog doc = document.getDocumentCatalog(); PDAcroForm Form = doc.getAcroForm(); String formName = "topmostSubform[0].Page1[0].pana_pania[0]"; PDField f = Form.getField(formName); setField(document, formName, "Artur"); System.out.println("New value 2nd: " + f.getValueAsString()); document.saveIncremental(new