PDF: Work with actions of PDF interactive form field
In This Topic
PdfInteractiveFormField.AdditionalActions property allows to define the following actions connected with the form field data:
PdfAnnotation.ActivateAction and
PdfAnnotation.AdditionalActions properties allow to define the actions, connected with the visual appearance of form. For example, the action that should be performed if the mouse button is clicked above annotation or the action that should be performed when the page with annotation has become visible.
The interactive form may include a field, the value of which must be recalculated if the value of any other field has changed.
PdfDocumentInteractiveForm.CalculationOrder property allows to define a list of fields selected for recalculation. The recalculation is performed in order of fields in the property.
To recalculate the field value dynamically is necessary to do the following:
- Create an action, which defines a JavaScript code that recalculates the filed value
- Specify that the created action should be used during recalculation of the field value
- Add the field into the list of fields selected for recalculation
Here are examples, which demonstrate how to create buttons with actions: