How to get the type of Field present in a PDF Form using PDFBOX. I mean if Radio button and check button is present in a PDF form it should return me Radio button or check button
but use getFieldType() method I’m able to returns only “Txt” for Text box and for Radio / Checkbox it return – “Btn”
PDDocument fdeb = null;
fdeb = PDDocument.load("C:\\Users\\Desktop\\Sample.pdf");
PDAcroForm form = fdeb.getDocumentCatalog().getAcroForm();
List FieldTy = form.getFields();
PDField pdfFields;
for (int i = 0; i < FieldTy.size(); i++)
{
pdfFields = (PDField) FieldTy.get(i);
String fieldNameTyope = pdfFields.getFieldType();
System.out.println(fieldNameTyope);
}
But i need to distinguish wat kind of button is that whether radio or check box or its a button
Can any one help me out Please
Thanks
I think this will help you