Need help to run java compiler on windows
Hi, i have windows 7 system and now i got problem during run java program on my system command prompt. i already installed java developer kit from Sun Microsystems, and JRE on my system. it installed successfully without any problem. today, i just made one java program and then try to run it on the command prompt using the javac command. My java file name is Javatest. So, i try to execute javac Javatest.java on command prompt as per mentioned in book. Then command prompt show me error "command not found". How is that possible?? i correctly installed java compiler on it but it won't detect in command prompt. Need help to fix this problem.
Re: Need help to run java compiler on windows
Ok, this is not the software or hardware problem. After installing java compiler in windows system, we need to set the environment variables path on system. This environment variable works to detect the command or exe file that presents in this path and set it as a global variable. so, that we can execute this exe file as a command on any drive of the system.
Re: Need help to run java compiler on windows
Quote:
Originally Posted by
Holbrook
Ok, this is not the software or hardware problem. After installing java compiler in windows system, we need to set the environment variables path on system. This environment variable works to detect the command or exe file that presents in this path and set it as a global variable. so, that we can execute this exe file as a command on any drive of the system.
I understand that issue but can you describe the easiest way to set this enviornment variables in my windows 7. I'm really waiting for it. Please describe its process on step by step manner.
Re: Need help to run java compiler on windows
Quote:
Originally Posted by
MashyB
I understand that issue but can you describe the easiest way to set this environment variables in my windows 7. I'm really waiting for it. Please describe its process on step by step manner.
Follow below process for setting java compiler file as a global variable.
Go to property window of my computer.
Then hit the advanced tab and click on Enviornment variables button.
After that you need to copy the jdk directory path from the java setup folder.
paste it to enviornment variables tab at the end of text.
Before paste this path, use semicolon (';') for separation within two path.
Click OK to finish this process.
that's it.
Now you can able to run this javac command on any drive on your command prompt.
Re: Need help to run java compiler on windows
The alternative choice is whenever you go to command prompt, simply use below code for setting jdk folder as a enviornment variables. Its well and i personally use it.
Quote:
set path="C:/Program files/Java/Jdk1.5";
Use it and check it by running javac command on your system.