We are trying to use Form.FillField() method to fill the attached PDF form (XFA based).
Here is the code we used. However the output PDF file still contains the old value (2016-0315) and did not have the new value (1122334455) assigned. Could you help on figuring out the issue?
Aspose.Pdf.Facades.Form pdfForm = new Aspose.Pdf.Facades.Form();
pdfForm.BindPdf(“cr-3_2015.pdf”);
foreach (string field in pdfForm.FieldNames){
if (field == @“form1[0].CaseID[0]”)
{
pdfForm.FillField(field, “1122334455”); //debug could step into this line of code
}
}
pdfForm.Save(“output.pdf”);