I recently downloaded JDK 1.8.0.0_06 that comes bundled with NetBeans. I then got to find out that my JavaFx project, that I have been developing in Java 1.7 won\'t compile in J
Most of the time, these type of issues happen due to incorrect java version. Make sure your PATH and JAVA_HOME variables are pointing to the correct version.
if you are going to step down, then change your project's source to 1.7 as well,
right click on your Project -> Properties -> Sources window and set 1.7 here" Jigar Joshi
Also go to the build-impl.xml
and look for the property excludeFromCopy="${copylibs.excludes}"
and delete this property on my code was at line 827 but I`ve seen it on other lines
for me was taking a code from MAC OS java 1.8 to WIN XP java 1.7
if you are going to step down, then change your project's source to 1.7 as well,
right click on your Project -> Properties -> Sources window
and set 1.7
here
note: however I would suggest you to figure out why it doesn't work on 1.8
For IntelliJ IDEA Ultimate latest version as of 18th Dec 2017, if the above suggestions don't work, then please try the following: Right Click on the project and navigate to "Open Module Settings". Open it, then change the "Language Level" from the dropdown.
Your javac is not pointing to correct java.
Check where your javac is pointing using following command -
update-alternatives --config javac
If it is not pointed to the javac you want to compile with, point it to "/JAVA8_HOME/bin/javac", or which ever java you want to compile with.
I got the same issue with netbeans, but mvn build is OK in cmd window. For me the issue resolved after changing netbeans' JDK (in netbeans.conf as below),
netbeans_jdkhome="C:\Program Files\Java\jdk1.8.0_91"
Edit: Seems it's mentioned here: netbeans bug 236364