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

Free Support Forum - aspose.com

PDF Kit - Default value for combo box is not correct

Hi,

We are using pdf kit for .net to render PDF templates.

I am trying to set a display value for the combo box(COMBO) from the source pdf to "Second" in the output pdf. To do this i use - form.FillField("COMBO","Second").

The problem is, when i flatten this particular field, the exported PDF shows "Second" as the value of the combo box and the combo box is set to read only as expected.

If i dont flatten it, then the combo box is selectable and all the values of the combo box are selectable, as expected. However, the listed value is not "Second", it is "First". Expected Behavior is that the default displayed value should be "Second".

Please let me know how to accomplish that. I have attached the source pdf document for your reference.

thanks,

Jaideep.

Hi Jaideep,

I have tested this issue using the latest version at my end, but couldn’t notice any problem. The values are selected and shown properly in the output file. I have used the following code snippet:


//create From object

Form form = new Form(“Untitled.pdf”, “output.pdf”);

//select value

form.FillField(“COMBO”, “Second”);

//save output form

form.Save();


Please download the latest version and try at your end. If you still find the same problem, please do let us know.

We're sorry for the inconvenience.
Regards,