It seems like removing a PDField from a loaded PDDocument would be trivial.
The goal is to remove the field from the form and anything related to that 
field from the displayed PDF.

I have tried just removing the PDField from the List of PDAcroForm.getFields() 
which does not seem to work.

And I have tried digging into the PDAcroForm's dictionary:
    PDField pdField = pdAcroForm.getField("boxAPPL");
    COSDictionary formDict = pdAcroForm.getCOSObject();
    COSArray fieldz = (COSArray) formDict.getDictionaryObject(COSName.FIELDS);
    fieldz.removeObject(pdField.getCOSObject());

which does not appear to work either.

Any is help appreciated.


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to