Monday, November 18, 2013

Display or List Environment Variables in Windows

Environment variables are a set of dynamic named values that can affect the way running processes will behave on a computer.
They are part of the operating environment in which a process runs. For example, a running process can query the value of the TEMP environment variable to discover a suitable location to store temporary files, or the HOME or USERPROFILE variable to find the directory structure owned by the user running the process.

To view the contents of the environment variables:

1. open command prompt (write "cmd" in search bar of the start menu or in Run)
2. To list -> write "set" (without quotes) and hit enter
    To save it into file -> "set > output.txt" and hit enter
I.e. The file will be saved in C:\
To save the file in other directory "set > D:\output.txt" and hit enter