5.3 for Windows

Table Of Contents
FOXIT READER 5.3
User Manual
139
Using JavaScript Console
JavaScript Console is a control panel for the execution and debugging of
JavaScript code. Serving as a debugging aid, it is quite useful for displaying
debug messages and executing JavaScript.
To active the JavaScript console, select Forms > JavaScript Console, and do the
following:
Using Document JavaScript Command
Document JavaScripts are variable and function definitions that are generally
useful to a given document, but are not applicable outside the document.
Variable definit ions: Define variables at the document level to make them
visible to any executing script.
Function definitions: Define functions at the document level that support
the user interaction with the document. These functions may be utility
functions for handling common tasks for string or number manipulation, or
functions that execute lengthy scripts called by actions initiated by a user
A. In the pop-up Javascript
Console dialog box, type
your JavaScript code, or
click Open and select one of
the file with js format.
B. Click Run button to run your
JavaScript code. You will be
prompted that the code has
run successfully. W hen the
code goes wrong, it gives
you an error message in the
message box below..