Free Support Forum - aspose.com

Unable to get all field in pdf form

Hi,

I am a new aspose.pdf developer and I want to get all field from pdf file in attached.
But it show only 5 field and all field is textbox

private void GetContent()
{
Document pdfDocument = new Document(Server.MapPath("~/PD/IN01_application_to_register_a_company.pdf"));
String strformField = string.Empty;

//open document
List listFields = new List();
//Document pdfDocument = new Document(“E:\AP Data\Demo.Pdf”);
foreach (Field formField in pdfDocument.Form)
{
getField(formField, ref listFields);
}
}
public void getField(Field field, ref List listFields)
{
if (field.IsGroup)
{
foreach (Field childField in field)
{
getField(childField, ref listFields);
}
}
else
{
listFields.Add(field.FullName);
}
}

This is asp.net by c# code
Can anyone help me?

Thank,
Phanu282003

I already get all field by
Aspose.Pdf.License license = new Aspose.Pdf.License();
license.SetLicense(Server.MapPath("~/Aspose.Pdf.lic"));


Thank

Hi Phanuwat,


Thanks for your interest in Aspose. Its good to know that you have managed to get your desired results.

Please feel free to contact us for any further assistance. We will be more than happy to help you.

Best Regards,