We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Using aspose pdf to pre-fill data to 2014 W4 form

Hi,
I’m having an issue to update data to the field c1_01[0], c1_01[1], c1_01[3] which stands for “single”, “married” & “married, but…” checkbox on the 2015 W4 form. For some reason, I’m getting an error “c1_01 can’t be defined as global field & non-global field” when open up the pdf. do you have any advise?
Question 2, for the employee’s signature & date fields. how do you pre-fill values to it since they don’t have field names? As a reference, assign “signature” & “date” on 2013 W4 works well but not the 2015 form.
thanks

Hi,


Thanks for contacting support.

In order to fill form field, you need to provide exact name of the field. So as per your requirement, if you need to enable check for particular form field, first you need to identify its name. Please visit the following link for information on how to Identifying form fields names

Furthermore, once the name of field is identified, you can use the following code snippet to enable checkbox in PDF document. For your reference, I have also attached the resultant file generated over my end.

[C#]

//open
document
<o:p></o:p>

Document pdfDocument = new Document("c:/pdftest/fw4.pdf");

// get reference of checkbox field

CheckboxField check = pdfDocument.Form["topmostSubform[0].Page1[0].c1_01[0]"] as CheckboxField;

//modify field value

check.Checked = true;

//save updated document

pdfDocument.Save(“c:/pdftest/Filled_output.pdf”);

Hi,
Thanks for your reply. I found the issue which is I had a old version of the aspose.dll which don’t have the checkboxfield class.
I have another issue with the “employee’s signature” & date fields. I don’t see there are fields name for those fields. is it possible that I can pre-fill the signature & date fields?

Hi,


I have observed that name for Signature and Date field are not being recognized by our API. I have logged this problem as PDFNEWNET-38118 in
our issue tracking system. We will further look into the details of this
problem and will keep you updated on the status of correction. Please be
patient and spare us little time. We are sorry for this inconvenience.

However if you need to digitally sign the PDF document, you may follow the instructions specified over Digitally sign PDF file