ENVIRON({envstring | number})

Returns information about the current operating system environment (String).

envstringThe name of an environment variable (String).
numberThe number of the position in the environment-string table (?).

* The number argument can be any numeric expression, but is rounded to a whole number before it is evaluated.
* If there is no environment string in the corresponding position, then a zero length ("") is returned.
* You can use the ENVIRON$ function to return a String data type instead of a Variant/String data type.
* This function is not available on the Macintosh.
* The equivalent .NET function is Microsoft.VisualBasic.Interaction.Environ
* For the Microsoft documentation refer to docs.microsoft.com

Environ(1) = "prompt"
Environ(2) = "temp"
Environ(3) =
Environ("UserName") = "rproctor"
Environ("UserProfile") = "C:\Documents and Settings\rproctor"
Environ("HomeDrive") = "C"
Environ("HomePath") = "\Documents and Settings\rproctor"
Environ("Logon Server")
Environ("ProcessorRevision") - ??

© 2020 Better Solutions Limited. All Rights Reserved. © 2020 Better Solutions Limited Top