Appendix A A Short Acrobat Javascript Faq; Where Can Javascripts Be Found And How Are They Used; Folder Level Javascripts; Document Level - Adobe 12001196 - Acrobat - Mac Manual

Javascript
Hide thumbs Also See for 12001196 - Acrobat - Mac:
Table of Contents

Advertisement

A

Where can JavaScripts be found and how are they used?

JavaScripts work with Acrobat on a variety of levels: the folder level, document level, field
level and batch level.These levels restrict the type of processing that can occur and are
loaded at different times.

Folder Level JavaScripts

JavaScripts can be placed in individual files with the ".js" extension. For such files to be
read by the viewer at startup they need to be placed in either the Acrobat Application
JavaScripts folder or in the user's JavaScripts folder. See
section of the
are loaded into the application on startup.
You should place variables and functions that might be generally useful to the application
in these folders. Note that some JavaScripts methods can only be executed from within one
of these JavaScript files at startup, for example,
There are some restrictions when writing JavaScript files, particularly with respect to the
use of the default
The standard Acrobat JavaScript implementation comes with three JavaScript files:
Aform.js which contains built-in pre-canned functions, Annots.js which is used by the
Annotations plug-in and ADBC.js used by the ADBC plug-in. These are located in the
application JavaScripts folder.
The file glob.js is programmatically generated and contains cross-session application
preferences set using the global object's setPersistent.
If the file Config.js is present, this file can be used to customize the look of the viewer by
removing toolbar buttons and menu items (see the
hideToolbarButton).

Document level

By using the Adobe Acrobat menu item Advanced > JavaScript > Document
JavaScripts..., you can add, modify, or delete document level scripts. These scripts should
be function definitions that are generally useful to the document but are not applicable
outside the document. Document level scripts are executed after the document has
opened and after the plug-in level scripts are loaded. Document level scripts are stored
1. Frequently Asked Questions
Acrobat JavaScript Scripting Guide
A Short Acrobat JavaScript FAQ
Acrobat JavaScript Scripting Reference
this
Object.
App/Init
for a discussion of the order these files
and addSubMenu.
addMenuItem
and
hideMenuItem
1
in the
Event Object
75

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Acrobat 6.0

Table of Contents