Microsoft Office Tutorials and References
In Depth Information
DISCOVER THE TEMP FOLDER PATH
Each entry in the list contains the environment variable name, an equals sign,
and the value on that computer. When you know what variable names are
available, you can pass the variable name in quotes:
Msgbox "You are signed in as " & Environ("USERNAME") & " to
domain " & _
Environ("USERDOMAIN")
Some common environment variables that appear on most systems include:
ALLUSERSPROFILE
APPDATA
CommonProgramFiles
COMPUTERNAME
ComSpec
FP_NO_HOST_CHECK
HOMEDRIVE
HOMEPATH
LOGONSERVER
NUMBER_OF_PROCESSORS
OS
Path
PATHEXT
PROCESSOR_ARCHITECTURE
PROCESSOR_IDENTIFIER
PROCESSOR_LEVEL
PROCESSOR_REVISION
ProgramFiles
SESSIONNAME
SystemDrive
SystemRoot
TEMP
TMP
USERDOMAIN
USERNAME
Additional Details: The Environ function does not work in the Excel grid.
You can build a user-defi ned function to make it available to the Excel interface.
To do so, use this code:
Function MyEnviron(ByVal Key)
MyEnviron = Environ(Key)
End Function
 
Search JabSto ::




Custom Search