![]() There are several ways to invoke the JavaScript Editor, depending on the context. ![]() In the text window, type the following code: In the debugger, select Console > from the View window.Ĭlick Clear (the trash can icon), located at the bottom right of the Console, to delete any contents that appear in the window. Select Tools pane > Javascript > JavaScript > Debugger or open the JavaScript Debugger. This ensures that whenever you make mistakes, the console displays helpful information.Ĭlick OK or close the Preferences dialog box. Select Show Console on Errors and Messages. This option enables you to evaluate code that you write in the console window. In the Preferences dialog box, select Enable JavaScript Debugger After Acrobat is Restarted from the JavaScript Debugger options. Select Enable Acrobat JavaScript if it is not already selected. Select JavaScript from the list of options on the left side of the dialog box. Select Edit > Preferences or open the Preferences dialog box. To enable JavaScript, the Debugger and the Console: In order to execute code from the console, you will also need to ensure that the JavaScript Debugger is enabled, since the Console window is a component within the JavaScript Debugger interface. In order to use JavaScript, you must first verify that JavaScript has been enabled. To indent four spaces to the left, position the cursor at the beginning of a single line or highlight a block of code and press Shift + Tab. To indent four spaces to the right, position the cursor at the beginning of a single line or highlight the block of code, and press the Tab key. To indent code in the JavaScript console, use the Tab key. In all cases, the result of the most recent single JavaScript statement executed is displayed in the console. To evaluate multiple lines of code, highlight those lines and press either the Enter key on the numeric keypad or press Ctrl + Enter. To evaluate a single line of code, make sure the cursor is positioned on that line and press either the Enter key on the numeric keypad or press Ctrl + Enter. To evaluate a portion of a line of code, highlight the portion and press either the Enter key on the numeric keypad or press Ctrl + Enter. There are three ways to evaluate JavaScript code while using the interactive console: The JavaScript console allows you to evaluate single or multiple lines of code. To open and close the console with JavaScript code, use console.show() and console.hide() methods, respectively. Select either Console or Script and Console from the debugger View list. Type Ctrl+J > (Windows) or Command+J (Mac OS) Select Tools pane > JavaScript > JavaScript Debugger > or Open the Debugger window using one of these methods:
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |