Linking Scripts to Toolbar Buttons
You can use scripts by adding them as buttons to the Scripting toolbar, then clicking on their button. The Scripting toolbar has two buttons by default, Manage Scripts and Stop Script . Scripts added to the Scripting toolbar will appear right of these buttons.
How to link a script to a toolbar button
- Enable the Scripting toolbar by doing one of the following:
- From the top menu, select Windows > Toolbars > Scripting.
- Right-click on any toolbar and select Scripting.
- In the Scripting toolbar, click the Manage Scripts button.
The Scripts Manager dialog box opens and displays the available scripts.
- In the Files list, select the JavaScript file containing the function you want to add to the toolbar.
- In the Functions list, select the function to add to the toolbar.
- Click the Right Arrow button to add the function to the In Toolbar list.
- To load a custom icon, click Customize Icon and browser for a
*.png
,*.jpg
or*.xpm
file.
- To customize the tooltip appearing in the Scripting toolbar, click Customize Tooltip and type in the new tooltip in the Function Tooltip window.
- Click OK.
The script is added as a new button on the Scripting toolbar. You can press on the script's toolbar button to execute the script.
TIP: You can stop a script while it is running by pressing the Esc key or clicking on the Stop button on the Scripting toolbar.