2 Replies Latest reply on Apr 21, 2009 9:25 AM by gkaiseril

    how to call that javascript file?

    mariaprabu Level 1

      I developed javascript for automated pdf files. But i don't know how to call that javascript file from outside of acrobat. Kindly advice me the various way to use that script. This is for acrobat 8.0 for windows platform.

        • 1. Re: how to call that javascript file?
          Patrick Leckey Level 3

          You can call custom folder-level or document-level functions from external applications by using the JSObject bridge.  How you access this depends on what language you are developing your external application in and how you are interfacing with Acrobat, which you did not explain so I cannot offer any insight.

          • 2. Re: how to call that javascript file?
            gkaiseril MVP & Adobe Community Professional

            You can place Acrobat JavaScripts in various form elements, document actions, documents, and the application folder or user application folder. See the Acrobat JavaScript API Reference and Guide fo rmore information, http://www.adobe.com/devnet/acrobat/javascript.html .


            From within Acrobat's JavaScript's debugging console, one can use the following code to locate the JavaScript folders used by Acrobat/Reader:


            function JSInfo() {

            /* define function to report JS information */

            // some basic system information
            console.println(app.viewerType + ' ' + app.viewerVersion + ' is running on ' + app.platform);
            // user level script folder
            try {
            var userJS = 'User level JS folder: ' + app.getPath("user","javascript");
            } catch(e) {
            var userJS = "User has not defined use JS folder level scripts";
            // application level script folder
            try {
            var appJS = 'Application level JS folder: ' + app.getPath("app","javascript");
            } catch(e) {
            var appJS = "There are no defined application level JS folder level scripts";


            } // end of JSInfo function


            JSInfo(); // call the function