Reputation: 2505
I am working in Win 7. So I have set the Path variable inside properties, environment variables. But when I e.g. type java in command line it doesn't recognize it up until I write set Path=... And set the exact same thing I have already manually set in the properties env variable window. And then it works. But again when I close the command line and re-open it, it doesn't recognize javac. So every time I open the command line I have to set the Path. Any idea?
Upvotes: 2
Views: 2129
Reputation: 484
In Windows using set from the command line only sets the environment variable for that process. When you are doing it from the command line and then closing it, you are losing what you did there.
You say Properties, Environment Variables, but let me run through the steps so that we're on the same page.
To make sure an environment variable "sticks" click the Start button, Right Click "Computer" and choose Properties. Click Advanced System Settings and then Environment Variables... In the dialog that comes up, under the System Variables section double click on the Path environment variable. Scroll to the end, add a semi-colon, and then add the path to your executable.
You will now have to restart any process that was already running.
Upvotes: 1