Skip to main content

Interface: FieldActions

JavaScript actions attached to a form field.

Key mapping (ISO 32000-2 Table 217):

  • keystroke → /K (Keystroke action)
  • format → /F (Format action)
  • validate → /V (Validate action)
  • calculate → /C (Calculate action)

Each string is raw PDF JavaScript source code. The library emits each non-null action as a PDF stream object referenced from the /AA dictionary on the field annotation.

Properties

PropertyTypeDescription
calculate?stringCalculate JS → /C in the /AA dict.
format?stringFormat JS → /F in the /AA dict.
keystroke?stringKeystroke JS → /K in the /AA dict.
validate?stringValidate JS → /V in the /AA dict.