Keywords - Function groups - @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

Group: Information and Control
See also: getenv library

Function: setenv
Description: setenv sets one of the environment variables described below to a desired value

Usage: setenv (envname, newval)
Input:
envname string, name of the environment variable envname can take the following values:
"xpl4data"
directory for loading (reading) data
"xpl4lib"
directory for loading libraries
"xpl4dll"
directory for loading a dynamically linked library (used by dlopen)
"xpl4help"
directory for loading help system
"xpl4outdata"
directory for writing data
"xpl4outhelp"
directory for user taylored APSS (not used)
"xpl4outprog"
directory for writing programs
"xpl4outtemp"
directory for writing temporary files
"outputformat"
format of numerical output. Syntax like C's printf
"outputstringformat"
format of textual output. Syntax like C's printf
"outheadline"
format of the headline of an array in the standard output
"outlayerline"
format of the layerindex of an array in the standard output
"outlineno"
format of the line number of an array in the standard output
"outmaxdata"
maximum number of data items in the output window
"browser"
WWW browser started from XploRe (under Windows this is the default browser)
"logfile"
directory containing logfile
"startup"
name of the startup file
"port"
portnumber used (only XploRe server)
"maxClients"
maximal number of clients (only XploRe server)
newval string, new value for the desired environment variable (e.g., name of a directory)

Note:

Example:
setenv("xpl4data", "/user/haerdle/project1/data")

Result:
data are read from /user/haerdle/project1/data
Example:
setenv("outheadline", "")
x = normal(3,3,3)
x

Result:
the array is displayed without the standard header "contents of x"
Example:
setenv("outputformat", "%10.2f")
x = normal(3,3,3)
x

Result:
numbers are printed rounded to two digits
Example:
setenv("outheadline", "")
setenv("outlayerline", "")
setenv("outlineno", "")
x = normal(3,3,3)
x

Result:
the array is displayed without the standard header "contents of x",
    without the array line number (e.g. "[1,]", etc.) and without the layer index (e.g."[,,1,1,1,1,1,1]", etc.)



(C) MD*TECH Method and Data Technologies, 05.02.2006