Adobe 23101335 Scripting Guide - Page 26
JavaScript Debugging, running the JavaScript from the UI without holding down the modifier key.
UPC - 718659152833
View all Adobe 23101335 manuals
Add to My Manuals
Save this manual to your list of manuals |
Page 26 highlights
Scripting basics 2 Testing and troubleshooting 2.10.3 JavaScript Debugging This section describes the information and controls that the main Script Debugger window provides. In Photoshop you can use the JavaScript Debugger Window to step through your JavaScript code. JavaScript can be executed in two different ways: from the UI via the "Scripts..." menu and from AppleScript of VisualBasic via the do javascript methods. When running JavaScript from the UI you must hold down the option key on the Mac and alt on Windows to activate the debugger. When you hold down this modifier key the "Run Script" button changes to "Debug Script". When invoking JavaScript from AppleScript or VB you must set the show debugger argument appropriately. If you set show debugger to never you will disable debugging. This corresponds to running the JavaScript from the UI without holding down the modifier key. If you set show debugger to on runtime error your JavaScript will execute normally until it detects a run-time error or until it meets a "debugger;" call (see below for an example). When this happens execution will be stopped and the JavaScript debugger will be shown. If you set show debugger to at beginning your JavaScript will halt before executing the first line of JavaScript code and the debugger will be shown. This mode corrseponds to executing JavaScripts from the UI while holding down the modifier key. Photoshop 7.0 Scripting Guide 26