Environment
Situation
Resolution
Steps to have the debugger automatically appear for client and server scripts.
1. In the client, goto element, Administration->Automation->Scripts
2. Right click on Scripts and select Properties
3. Click on the "Debugger" button
4. Select the "Options->Open Debugger" menu
5. Select the appropriate option for your debugging needs
6. Close the debugger and properties pages, you do not have to hit a save button
Whenever the debugger is visible you can change the debugger options using step 4 and 5. This setting is global for all users and will last till the next server restart.
For server-side script debugging that is available over server restarts, properties can be added to the ../config/Formula.properties file or to the Formula.custom.properties file. Client-side script debugging must have properties added to the ../html/client/applet_params.xml file.
Prompting to Start Debugger For All Script Invocations The scripting framework will prompt you to debug any script that is executed within your environment if you add the following property to the appropriate context:
Script.debug=true
Debugging All Script Invocations To debug any script that is executed within your environment, add the following property to the appropriate context:
Script.debug=all
Debugging a Specific Script Invocations To debug a specific script that is executed within your environment, add the following property to the appropriate context:
Script.debug=<script name>
Instrumenting Your Script For Debugging Alternately, you may simply add the following comment to your script, and theFormulaScript? debugger will be opened when the script is executed. Remember to remove this before sending the script to production!
// @debug on
You may keep a similar comment in your code to make a quick-switch to debug mode:
// @debug off