Using Acrobat JavaScript in Forms
Forms Essentials
6
Enabling Dynamic Layout and Rendering
In order to enable dynamic layout and rendering for a form, save it from LiveCycle Designer
as a "Dynamic PDF Form File".
Growable Form Fields
The elements, which include Fields, Subforms, Areas, Content Areas, and Exclusion Groups,
expand to fit the data they contain. They may relocate in response to changes in the
location or extent of their containing elements, or if they flow together with other elements
in the same container.
If the element reaches the nominal content region of the containing page, then it splits so
that it may be contained across both pages.
Variable-Size Rows and Tables
Subforms may repeat to accommodate incoming data. For example, when importing a
variable number of subforms containing entries for name, address, and telephone number,
form fields need to be added or removed based on the volume of data. This means that the
number of rows in a table may increase.
Multiple Customized Forms within a Form Based on User Input
Subforms may also be subject to conditions. For example, form fields for dependent
children would become visible if the user checks a box indicating that there are dependent
children. In addition, XFA allows multiple form fields with the same name and multiple
copies of the same form.
Handling Image Data
Images are handled as data and are considered to have their own field type. There is
automatic support for browsing images in all standard raster image formats (including
PNG, GIF, TIFF, and JPEG).
Dynamic Tooltips
XFA forms support dynamic tooltips, including support for individual radio buttons in a
group.
XFA-Specific JavaScript Methods
Acrobat JavaScript provides access to the XFA
appModel
container, which provides the
properties and methods indicated below in
Table 6.6
and
Table 6.7.
T
ABLE
6.6
appModel Properties
appModel Property
Description
The node represented by the alias for this model
Returns all nodes with the same name or class
Returns
xfa
aliasNode
all
appModelName
Acrobat JavaScript Scripting Guide
109