go to previous page   go to home page   go to next page        


Not usually.

PATH variable

Usually you create a disk directory someplace convenient to hold the various source files for a new project. You would like to run the compiler while working in that directory. The Windows operating system uses an environment variable called PATH that is a list of all the disk directories where it should look to find programs. To see what is in your PATH variable, type PATH in your command prompt (DOS) window. (To start a command prompt window, click on Start, then click on Run. Enter "cmd" in the Open: text box, then click OK.)

The system types out PATH= followed by a list of disk directories separated with semicolons. Exactly what you see depends on your OS and what you have done with it. If you don't see

C:\Program Files\Java\jdk1.6.0_07

(or similar) in your PATH you will have to edit your PATH variable. The above picture does not show the directory for Java in the PATH, so the Java compiler will not run from the default directory. The error message following javac shows this problem.


Can the PATH variable be changed?