Environ function (LotusScript Language)

Returns information about an environment variable from the operating system.

Syntax 1

Environ[$] ( { environName | n } )

Elements

environName

A string of uppercase characters indicating the name of an environment variable.

n

A numeric value from 1 to 255, inclusive, indicating the position of an environment variable in the environment string table.

Return value

Environ returns a Variant, and Environ$ returns a String.

If you specify the environment variable by name with environName, LotusScript® returns the value of the specified environment variable. If that environment variable is not found, LotusScript returns the empty string (""). If environName is the empty string or evaluates to NULL or EMPTY, LotusScript generates an error.

If you specify the environment variable by position with n, LotusScript returns the entire environment string, including the name of the environment variable. If n is larger than the number of strings in the environment string table, LotusScript returns the empty string ("").

If n is less than 1, greater than 255, an EMPTY Variant, or NULL, LotusScript generates an error.

Language cross-reference

@Environment function in formula language

ENVIRONMENT keyword in formula language

Example


Additional Documentation | Trademarks |