Hello I have WIn2000(Professional) and I installed JDk 1.3. I wrote small JAva program on notepad than save as Hello.java. After that I open cmd.exe and wrote javac Hello.java on the next line java HEllo. But It gave me the error: 'javac' is not recognized as an internal or external command, operable program or batch file.Does anybody can help me? Thanks Mike
posted 14 years ago
Most likely a path problem. Right click on your "My Computer" icon to open up the System Properties box. Select the Advnaced tab, where you'll see two window panes. The bottom is the System variables pane. Click on the Path variable, and hit the Edit... button. Append ";C:\jdk1.3\bin;" (assuming you've installed the jdk in the C: directory). Click okay, reopen your command prompt and try it again. Another way is to make a "set environment" batch file. In notepad, enter the following text:
set PATH=C:\jdk1.3\bin;%PATH% Again, assuming your jdk is in the C root. Save this file as "setEnv.cmd" (or anything with a .cmd or .bat ending), and run it before you need to do any compiling.