Running Scripts from the Command Line

 

You can run scripts from a command prompt without having to manually load and execute the script in Scripter. The same commands that you would type at a command prompt may also be entered as the "target" for a shortcut in order to link a shortcut button to a script. Enter the following to run a script from the command line or to link a shortcut to particular script file:

 

<Scripter path> -x filename.bas

 

where <Scripter path> represents the path to the Scripter program file. (for example, C:\ ProgramFiles\MapViewer\Scripter\Scripter.exe"), and filename.bas represents the name of the script to run. The space between the –x and the file name is required. This command opens the Scripter window, loads the specified script file, and runs the specified script. When the script terminates - either successfully or unsuccessfully - the Scripter window closes.

 

To load a script file but not execute it, the following command can be used:

 

<Scripter path> filename.bas

 

This opens the Scripter window and automatically loads the specified script file. The Scripter window remains open.

 

 

See Also

Running Scripts

Introducing Scripter

MapViewer Object Model

Object Hierarchy