Creating and editing scripts in the Script Editor

You can use the Script Editor to create or edit scripts by typing the required ACLScript syntax, or by using one of the other methods for entering syntax. When you create or edit a script you must ensure that each command is entered on a separate line.

To create or edit a script in the Script Editor:

  1. Complete one of the following steps to open the script in the Script Editor:
    • To create a new script, select File > New > Script.

    • To open an existing script, right-click the script in the Overview tab in the Project Navigator and select Edit.

  2. Complete any of the following steps, or use them in combination, to create or edit a script:
    • Create or edit the script by adding, modifying, or deleting ACLScript commands or command parameters in the Script Editor.

      Pressing Ctrl+Z allows you to Undo one or more actions. Ctrl+Y allows you to Redo one or more actions. Ctrl+S saves the ACL project, including the open script.

    • Select the checkbox beside one or more commands in the Log tab in the Project Navigator and right-click in the Log tab and select Copy. In the Script Editor, position the cursor where you want to insert the command(s) and right-click and select Paste.

    • Insert command syntax automatically for one or more commands by clicking Start Syntax Capture  in the Script Editor toolbar and using the ACL menus and dialog boxes to run commands with the required parameters. While syntax capture is enabled the command syntax is recorded in the script, but the commands are not processed. Click End Syntax Capture  to stop recording command syntax in the script. This functionality is distinct from the Script Recorder, which is a separate tool that records commands that have been executed by ACL.

    • Select an existing ACLScript command in the script and click Edit Command  in the Script Editor toolbar to edit the command parameters using the associated dialog box. For example, the Count dialog box is displayed if you click Edit Command  when the ACLScript COUNT command is selected.

    • Click Build New Dialog  in the Script Editor toolbar to create and insert the command syntax for a user-defined dialog box where the cursor is positioned in the Script Editor.

    • Copy and paste commands from another script, or from the Results tab.

  3. Complete any of the following options to insert command syntax or the names of ACL project items into your script:
    • Click Group , Else , End , or Loop  in the Script Editor toolbar to insert the command where the cursor is positioned in the Script Editor. The associated dialog box is displayed for the GROUP, ELSE, and LOOP commands which you can use to specify command parameters.

    • Right-click and select Insert > Field to display the Insert Fields dialog box. Select one or more fields to insert the field name(s) in the Script Editor and click OK.

    • Right-click and select Insert > Date & Time to display the Date & Time Selector dialog box. Enter or select the date, datetime, or time to insert in the Script Editor and click OK.

    • Right-click and select Insert > Expression to display the Expression Builder dialog box. Create the expression to insert in the Script Editor and click OK.

    • Right-click and select Insert > Project Item to display the Insert Project Item dialog box. Select the type of project item from the Item Type drop-down list and then select one or more items to insert the item name(s) in the Script Editor and click OK.

  4. Select File > Save Project.
  5. Click Yes in the confirmation dialog box.
  6. If you want to test the script by running it, click Run  in the Script Editor toolbar.


(C) 2013 ACL Services Ltd. All Rights Reserved. | Send feedback