Run Script

images/download/attachments/113546859/CmdRunScript.svg

This command allows to execute a script

No required selection to launch the command.

images/download/attachments/113546859/image2021-3-17_14-33-59.png

The console window is a text editor, with the following features:

  • images/download/attachments/113546859/ActionNewDocument.svg Create a new empty file (CTRL + N)

  • images/download/attachments/113546859/ActionOpenDocument.svg Open an existing script file (CTRL + O)

  • images/download/attachments/113546859/ActionSaveDocument.svg Save script file (CTRL + S)

  • images/download/attachments/113546859/ActionSaveAsDocument.svg Save script as a new file (CTRL + SHIFT + O)

  • images/download/attachments/113546859/CmdRun.svg Execute the whole script (F5)

  • images/download/attachments/113546859/CmdRunDebug.svg Execute the script step by step (F7)

  • images/download/attachments/113546859/CmdStop.svg Stop the current execution (ALT +F5)

  • images/download/attachments/113546859/CmdExternalFile.svg Switch to External file mode (CTRL + E)

  • images/download/attachments/113546859/CmdAddToFavorite.svg Add the current script to favorites

  • images/download/attachments/113546859/CmdHelp.svg Open help of Script functions (CTRL +F1)

The script dialog must have the focus for the shortcuts to activate.

The text editor features syntax coloration, static analysis and code completion based on the types and functions available through the script API to help you writing code even more easily:

images/download/attachments/113546859/image2019-6-25_16-52-2.png

If you want to write your scripts into an external text editor (for example, to edit more than one file at a time), we recommend Visual Studio Code. It provides the same core functionnalities.

In order to benefit from documentation and code completion inside VSCode, you will have to provide the path to the description file (.d.ts) containing the description of the script API. The description file is located into the installation folder.

To do so, just put the following comment at the top of your script (the triple slash /// are required):

/// <reference path="C:\Program Files\Leica Geosystems\Cyclone 3DR\Script\JsDoc\Reshaper.d.ts" />