[ https://issues.apache.org/jira/browse/PDFBOX-2761?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jason Mackin updated PDFBOX-2761: --------------------------------- Comment: was deleted (was: This Form throws: org.apache.pdfbox.pdmodel.interactive.annotation.PDAnnotationWidget cannot be cast to org.apache.pdfbox.pdmodel.interactive.form.PDFieldTreeNode) > Casting error for PDRadioButton when trying to exportFDF > -------------------------------------------------------- > > Key: PDFBOX-2761 > URL: https://issues.apache.org/jira/browse/PDFBOX-2761 > Project: PDFBox > Issue Type: Bug > Components: AcroForm > Affects Versions: 2.0.0 > Reporter: Jason Mackin > > When trying to exportFDF() in PDAcroForm.java, there is a ClassCastException > thrown when addFieldAndChilden(PDFieldTreeNode docField, List<FDFField> > fdfFields) is called and the docField is a PDRadioButton that has kids and > one is a PDWidget. > PDRadioButton.getKids() says: > "This will get all the kids of this field. The values in the list will either > be PDWidget or PDField. Normally they will be PDWidget objects unless this is > a non-terminal field and they will be child PDField objects." > But when kids are returned in the addFieldAndChilden method and one is a > PDWidget (PDAnnotationWidget in my case), it tries to cast it as a > PDFieldTreeNode and throws the exception. -- This message was sent by Atlassian JIRA (v6.3.4#6332) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org For additional commands, e-mail: dev-h...@pdfbox.apache.org