Is the "set" command equivalent to defining an environment variable?

1

If the "set" command on Windows XP is used to set an environment variable in the terminal, why doesn't the environment variable appear in the environment variables list when you go Start -> rt click on My Computer -> Advanced tab -> Environment Variables?

O_O

Posted 2011-10-14T18:15:30.757

Reputation: 1 473

Answers

4

When you use the set command in a CMD window, you are only setting the environmental variable for that individual CMD shell. The variables visible in Start -> My Computer -> Advanced -> Environment Variables are the variables that are set to be persistent and global.

Use the setx command in Windows if you want to create a persistent Environment Variable. setx.exe writes to the registry. ENVVARS created with setx WILL be visible in Start -> My Computer -> Advanced -> Environment Variables.

Tim Kennedy

Posted 2011-10-14T18:15:30.757

Reputation: 355