Publishers of technology books, eBooks, and videos for creative people

Home > Articles

  • Print
  • + Share This
This chapter is from the book

Acrobat 7.0 Changes

The "Acrobat Multimedia JavaScript Reference", which appeared as a separate document in version 6.0.2, has been merged into the "Acrobat JavaScript Scripting Reference". See the section "Introduced in Acrobat 6.0.2" on page 675 for a listing of all Multimedia JavaScript objects, properties and methods.

Execution of JavaScript through a menu event is no longer privileged. There is now support for executing privileged code in a non-privileged context. See "Privileged versus Non-privileged Context" on page 8 for details.

In versions of Acrobat earlier than 7.0, the JavaScript files AForm.js, ADBC.js, Annots.js, AnWizard.js, media.js, and SOAP.js resided in the App JavaScript folder. Beginning with Acrobat 7.0, these files are not shipped with Acrobat Professional, Acrobat Standard or Adobe Reader. In their place, a precompiled bytecode is used to improve performance. The debugger.js file in the App folder is not included in the bytecode.

Files in the User JavaScript folder are not included in the precompiled bytecode file.

It is recommended that users put their own .js files in the User JavaScript folder, the same place where glob.js resides. JavaScript code that sets up menu items (addMenuItem, page 59) should be put in config.js in the User JavaScript folder. The location of this folder can be found programmatically by executing app.getPath("user","javascript") from the console.

Adobe Reader now has a console window. There is a preference under Edit > Preferences > General > JavaScript to Show console on errors and messages. In addition to errors and exceptions, the console can also be opened programmatically with See the console Object (page 164) for a few other details.

The debugging capability of the JavaScript Debugging window can be made available for Adobe Reader for Windows and Macintosh platforms. To debug within Adobe Reader, the JavaScript file debugger.js needs to be installed, and the windows registry needs to be edited appropriately. See the Acrobat JavaScript Scripting Guide for the technical details.

  • + Share This
  • 🔖 Save To Your Account