How to update the PATH variable on windows without logging off or rebooting

When you go to Computer->Properties->Advanced System Settings->Environment Variables you can change the PATH variable. But the general advice is that you have to log off or reboot to actually see the change.

I actually found a work-around:

  1. Change the PATH variable.
  2. Add a new variable, call it something random. Maybe something like CHANGE_TO_UPDATE and put a random value like x in it.
  3. Remember to restart cmd.exe or whatever program that needs to see the new path variable.

Voila! It should now work. When I didn’t do step 2, it did not work for me no matter which other solutions I tried.