Intellij编译时报“java: System Java Compiler was not found in classpath”

问题如下:

  1. IntelliJ 12 CE downloaded and installed
  2. Latest Java 1.7 downloaded and installed
  3. JDK was setup to make and run the project

I faced the following strange error

Error: java: System Java Compiler was not found in classpath

 

The solution that fixed my problem was as follows:

In:

Project Settings > Compiler > Java Compiler

I changed the drop down Use compiler from Javac to Eclipse!

Non of the other solutions I found on the web was helpful. Hope this helps you my unknown fellow reader.

IMPORTANT: THIS HAD NOTHING TO DO WITH MY JAVA_HOME AS IT WAS SET CORRECTLY.

郑重声明:本站内容如果来自互联网及其他传播媒体,其版权均属原媒体及文章作者所有。转载目的在于传递更多信息及用于网络分享,并不代表本站赞同其观点和对其真实性负责,也不构成任何其他建议。