Windows Environment Variables from Command Prompt

If you’re supporting an end user on Windows XP, Vista, 7, 8, or 10, and don’t want to completely log them out, you can use Run As on a Command Prompt as an administrator and then run the following:

rundll32 sysdm.cpl,EditEnvironmentVariables

Now edit your variables and relaunch your application. This is very useful if you find yourself needing to correct the PATH, let’s say, for Java.