English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

I keep on geting " 'javac' is not recognized as an internal or external command, operable program or batch file." after I enter it into my command prompt. I was told that I would have to set the path. I have gone to environmental variables and changed the user variables and the path for system variables so that it goes to my JDK SE (I think). I do not know what I am doing wrong. Any help would be greatly apriciated. Oh I have windows XP if you need to know.

2007-02-06 16:15:36 · 3 answers · asked by Michael M 4 in Computers & Internet Other - Computers

3 answers

Well, if you're in the command prompt and you want to run javac, you have to go to the directory where "javac.exe" is located, in order to execute it.

Mine is in "C:\Program Files\Java\jdk1.5.0_06\bin". Yours is probably someplace similar.

I also made a shortcut on my desktop to the command prompt, and made it so that it would start in that directory. That way i don't have to go through and find it every time.

2007-02-06 16:25:18 · answer #1 · answered by extton 5 · 1 0

javac is not an Internal Command. So when you type the javac command dos doesnt know where the command is so you are getting the error message.

You can set multiple patch. Default path is c:\windows\command where all the Dos commands are.

You can add the directory where the javac file is located using the SET PATH command. Type SET PATH /? for help.

You can also save the SETPATH Command in the Autoexec.bat file so that it would be run everytime you start your computer.

If you still need further clarifications please get back to me.

2007-02-07 00:46:49 · answer #2 · answered by Sunil Saripalli 5 · 0 0

You have to set path to recognize javac as an internal or external command. To do so, follow these simple steps:

For Ex: if you load ur java in "C:\Program Files\Java\jdk1.5.0_03\bin"
then you have to type in command promt as

C:\set path="C:\Program Files\Java\jdk1.5.0_03\bin", %path%;

after typing this command, press enter.
You have to do this everytime you open command prompt.
Thank you.

2007-02-07 01:46:42 · answer #3 · answered by Mad Tech 2 · 0 0

fedest.com, questions and answers