ENVIRON |
ENVIRON({envstring | number}) |
Returns information about the current operating system environment (String). |
envstring | The name of an environment variable (String). |
number | The number of the position in the environment-string table (Long). |
REMARKS |
* 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 data type. * Calling Environ("Path") removes duplicates on Office 365 but on Office 2016 duplicates are not removed. * This function is not available on the Macintosh. * The equivalent .NET function is [[Microsoft.VisualBasic.Interaction.Environ]] * For the Microsoft documentation refer to learn.microsoft.com |
Environ(1) = "prompt"
Environ(2) = "temp"
Environ(3) =
Environ("AppData") - "C:\Users\ 'user name' \AppData\Roaming"
Environ("ClientName")
Environ("ComputerName")
Environ("HomeDrive") = "C"
Environ("HomePath") = "\Documents and Settings\ 'user name' "
Environ("Logon Server")
Environ("Path")
Environ("ProcessorRevision") - ??
Environ("SessionName")
Environ("UserDomain")
Environ("UserName") = "user name"
Environ("UserProfile") = "C:\Documents and Settings\ 'user name' "
© 2024 Better Solutions Limited. All Rights Reserved. © 2024 Better Solutions Limited Top