Prior to Acrobat
8.0, in a static PDF form, the object’s formatting is saved when the
end user saves, closes, and reopens the form. In a dynamic PDF form,
the object’s formatting is not saved.
Important: Although it is possible to save an object’s formatting on a dynamic PDF form by using client-side scripting, it is not a recommended practice and should be avoided. If saving an object’s formatting is a requirement, you need to use a static PDF form.
Beginning with Acrobat 8.0, the state of all the objects is saved
and can be restored automatically or manually upon reopening. This
is controlled by the restoreState scripting property
on the root subform.
Object formatting, as well as the layout of a dynamic PDF form,
can change when any of the following form actions occur:
The user opens the form
The user imports new data
The user adds new data to the form
A client-side script is run
The following table compares the end-user experience using the
examples in the topic Applying formatting by using client-side scripts when saving as either
a static PDF form or a dynamic PDF form in Adobe Reader.
Form content
|
Static PDF form
|
Dynamic PDF form
|
A client-side script to change the border
color of a field. (See Guidelines for forms.)
|
The outline of the value area remains red
when the form is saved, closed, and reopened.
|
The outline of the object does not remain
red when the form is saved, closed, and reopened.
|
A client-side script to apply shading. (See Guidelines for forms.)
|
The fillable value area remains red when
the form is saved, closed, and reopened.
|
The object, including the value area, does
not remain red when the form is saved, closed, and reopened.
|
A client-side script to hide objects. (See Guidelines for forms.)
|
The value in the text field remains invisible
when the form is saved, closed, and reopened.
|
The text field does not remain hidden when
the form is saved, closed, and reopened.
|
Note: If restoreState is set to auto,
all of these changes are maintained if the document is saved and
then reopened in Acrobat 8.0.
For more
information, see restoreState in
the Scripting Reference.