Command Line Options
From SysCAD Documentation
Navigation: User Guide -> Command Line Options
Introduction
The command line options can be used:
- in a desktop shortcut for SysCAD (Target field)
- to run SysCAD from the DOS prompt
- to run SysCAD from within a batch (or cmd) file
DOS prompt example to start SysCAD: C:\SysCAD92\bin\SysCAD92
If the DOS or CMD prompt is used often, it is recommended to add the folder location of the SysCAD executable file to the system path to avoid having to give the full path every time SysCAD is called.
The SysCAD executable file (SysCAD92.exe) is normally found in the folder:
- SysCAD installed drive:\SysCAD92\bin
Options
In general, an example of the command line with its different options is as follows:
- SysCAD92 [/l] [/n] [/p] [/r:*.SPJ] [*[.SPJ]] [*.SSC]
All options are optional as indicated by the square brackets. The options are case sensitive. They may be in any sequence. The different switches are explained as follows:
- /l = location of SysCAD license.
- For example, if SysCAD is installed on the network, the license is located on the server machine, use this to point to the SysCAD License Location.
- /l:"f:\SysCAD92\ProBal_License"
- /l:"f:\SysCAD92\Dynamic_License"
- NOTE: Make sure the full path for the project is given. Path or project location containing spaces or long file-names should be enclosed in quotes.
- /n = starts a new instance of SysCAD.
- If SysCAD is already loaded and a command line is passed, the command is "sent" to the copy of SysCAD already loaded unless the /n option is specified. When commands are sent to an already loaded copy of SysCAD, the only recognisable command is the script file command; all other options are ignored.
- /p = prompt for reload of previous project.
- (This option can also be set on the Other page of the General options tabbed dialog box.)
- /r = automatically load and run the specified project.
- This is only required if the project is in dynamic mode.
- /r:"N:\SysCAD92\abc project\Stage one.spf\project.spj"
- NOTE: Make sure the full path for the project is given. Path or project location containing spaces or long file-names should be enclosed in quotes.
- /nocloseprompt = don't prompt for project save when closing
- [*.spj] = loads the specified project.
- If a filename with no extension is specified *.SPJ is assumed.
- If a project file (*.SPJ) is found then it is loaded - any subsequent projects would be ignored. The "/p" option would also be ignored if specified. The "/r:*.spj" option is also ignored if specified.
- NOTE: Make sure the full path for the project is given. Project path containing spaces or long file-names should be enclosed in quotes.
- [*.ssc] = loads the specified script command file.
- If any Command Scripts (*.SSC) are found then they are executed in the order they are specified on the command line. The "/p" option would be ignored if specified. Note that if any of the command scripts use the Exit command, then all additional script commands and script files will NOT be executed.
- NOTE: Make sure the full path for the script file is given. Path or project location containing spaces or long file-names should be enclosed in quotes.
Examples
Cmd or DOS prompt examples
C:\>SysCAD92\bin /n /l:"c:\program files\SysCAD License"
C:\>SysCAD92\bin c:\SysCAD92\tutorial\leach.spf
C:\>SysCAD92\bin c:\SysCAD92\tutorial\cfgfiles\leach.ssc
C:\>SysCAD92\bin c:\SysCAD92\tutorial\leach.spf\project.spj c:\SysCAD92\Tutorial\cfgfiles\example.ssc
C:\>SysCAD92\bin "c:\SysCAD92\test\Evap test.spf\project.spj" "c:\SysCAD92\command Script files\test.ssc"
Note: A VBA (Visual Basic Macro) can also be set up in MS Excel to Start and Run SysCAD and the command script files. See Starting and running SysCAD from MS Excel.
