Ask your own question, for FREE!
Computer Science 23 Online
OpenStudy (davidusa):

How do I make command javac work on the windows command prompt?

OpenStudy (rsmith6559):

If Windows can't find javac, you may have to either use an absolute path to javac, or add it's parent folder to the PATH environmental variable. If it can find javac, you can run: javac --help A simple compilation would be: javac sourceFile.java

OpenStudy (davidusa):

Thanks. I don't know why. but it just doesn't work. I really need it to. Quickly. Please help me. I've done the Path stuff in computer settings, installed, uninstalled, and reinstalled java jdk a few times, it doesn't work. Please help me.

OpenStudy (rsmith6559):

Any time you're having a problem with a command line program, copy, pasting and posting the command that you're using, and the response is very helpful figuring out what's wrong. A screenshot of the Command Prompt window is a good substitute.

OpenStudy (davidusa):

It says javac not recognized as internal or external command, operatable program, or batch file.

OpenStudy (rsmith6559):

Okay, I'm betting that you have the Java SE JRE. In English: Java Standard Edition Java Runtime Environment. This is the package that allows you to run Java. It consists of the Java Virtual Machine and some other runtime stuff. Really, I just wanted to introduce JVM. To program, and compile Java, you need the Java SE JDK (Java Development Kit). The JDK has all the runtime stuff also, but most importantly, javac is in this package. It can be challenging to find the JDK download page, but it is there.

OpenStudy (davidusa):

Yes i do. thanks for helping me. I got it now! I uninstalled it and deleted all jdk files, then did it again. Once. and it works now thanks

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!