Please enable JavaScript to view this site.

Vensim Help

Navigation: Reference Guide > DSS Supplement - Compiling, Automation & Publishing > Venapps > Command Descriptions > SPECIAL

SPECIAL>GETINFO, GETVARNAMES, GETVARATTRIB, GETRUNINFO

Scroll Prev Top Next More

These commands report on the open model or a saved run, for programs (AI agents among them) that drive Vensim through command scripts. They write their output only when Vensim is started with the -log option:

vensim -log "c:\my models\query.cmd"

With -log, the output goes to the standard output and to command.log in the working directory. Each block is enclosed in marker lines, BEGIN_... and END_..., so a program can find it. Without -log the commands do nothing visible. They are available in Vensim DSS, and not in the Vensim DLL, which has the equivalent functions.

Arguments are separated by a comma, not by |.

•SPECIAL>GETINFO writes what vensim_get_info returns for codes 5, 10 to 20 and 22, one line per code, prefixed with the code. Markers BEGIN_RUN_INFO and END_RUN_INFO.

•SPECIAL>GETVARNAMES|type,filter lists the variable names that match filter. type selects the kind of variable, with the codes of vensim_get_varnames: 0 for all, 1 for levels, 2 for auxiliaries and so on. Markers BEGIN_VARNAMES and END_VARNAMES.

•SPECIAL>GETVARATTRIB|attribute,varname writes an attribute of varname, with the codes of vensim_get_varattrib: 1 for units, 2 for the comment, 3 for the equation and so on to 15. Use 0 for all of them. Markers BEGIN_VARATTRIB and END_VARATTRIB.

•SPECIAL>GETRUNINFO|runfile writes everything vensim_get_run_info returns for the run runfile. Markers BEGIN_RUN_INFO and END_RUN_INFO.

With -log, SPECIAL>LOADMODEL also writes its messages between BEGIN_LOADMODEL and END_LOADMODEL, followed by a units check between BEGIN_UNITS_CHECK and END_UNITS_CHECK.

SPECIAL>LOADMODEL|mymodel.mdl

SPECIAL>GETVARNAMES|1,*

SPECIAL>GETVARATTRIB|3,Population

MENU>EXIT