ActivateFormField
Form fields, viewer interaction
Description
Dispatches the field's action for the given trigger event to the OnFormFieldAction handler instead of executing it inside the control
The action is looked up on the widget first and then on its base field; push buttons and signature widgets are dispatched even when they carry no action so the host can implement their click behaviour, and no action is interpreted or executed by the viewer itself, in particular JavaScript actions are handed over as typed data
Syntax
Delphi
Function TPDFlibViewer.ActivateFormField(FieldIndex: Integer; Const TriggerEvent: WideString= 'U'): Integer;Parameters
| FieldIndex | One-based form field index |
|---|---|
| TriggerEvent | PDF trigger event letter, the default 'U' stands for mouse-up |
Return values
| 0 | No handler is assigned to OnFormFieldAction, the field index is invalid, or no action exists for a field type other than push button and signature |
|---|---|
| 1 | The activation was handed to the OnFormFieldAction handler |
See also
TPDFlibViewer, BeginEditFormField, FocusNextFormField, FocusedFormFieldIndex