javac not recognized

后端 未结 11 1363
再見小時候
再見小時候 2020-12-10 06:33

What can I do when I keep receiving the error

\'javac\' is not recognized as an internal or external command, operable program or batch file

相关标签:
11条回答
  • 2020-12-10 06:53

    Common Error Messages from SUN Tutorial page

    0 讨论(0)
  • 2020-12-10 06:55

    Even if I had

    • JDK installed
    • JAVA_HOME defined
    • %JAVA_HOME%\bin present in my %PATH%

    I still had this error. I resolved it by eliminating the JRE from my path variable. It was put before JAVA_HOME, has no javac. It seems Windows can't find javac in JAVA_HOME\bin in this case.

    0 讨论(0)
  • 2020-12-10 07:01

    The link below gives a step by step explanation on how to set up java_home and path variables. JAVA_HOME setup

    0 讨论(0)
  • 2020-12-10 07:03

    Make sure %JAVA_HOME%/bin is on your %PATH% (or $JAVA_HOME on the $PATH in *nix).

    0 讨论(0)
  • 2020-12-10 07:03

    It means that it is not in your path. You have the following options:

    1) Change to the directory where javac lives before calling it.

    2) Use the full path to javac when making the call, e.g. C:\java\jdk1.6.0_12\bin\javac ...

    3) Add the javac directory to the PATH environment variable

    0 讨论(0)
  • 2020-12-10 07:06

    Step 4 (Update the PATH variable) of the JDK installation instructions explains what you should do to make it so that you can just type javac in the command prompt window.

    0 讨论(0)
提交回复
热议问题