title: Compiling any JavaFX project in NetBeans returns Unsupported major.minor version 52.0
body: <p>I see a number of similar questions</p>
  
  <ul>
  <li><a href="https://stackoverflow.com/questions/23208203/netbeans-8-0-unsupported-major-minor-version-52-0-error">Netbeans 8.0 Unsupported major.minor version 52.0 error</a></li>
  <li><a href="https://stackoverflow.com/questions/30757174/unsupported-major-minor-version-52-0-error">Unsupported major.minor version 52.0 Error (duplicate)</a></li>
  <li><a href="https://stackoverflow.com/questions/25252614/running-a-jar-i-compiled-unsupported-major-minor-version-52-0">Running a JAR I compiled: Unsupported major.minor version 52.0</a></li>
  <li><a href="https://stackoverflow.com/questions/24790834/cant-fix-unsupported-major-minor-version-52-0-even-after-fixing-compatibility">Can't fix Unsupported major.minor version 52.0 even after fixing compatibility</a></li>
  </ul>
  
  <p>But none with the same circumstances as mine.  I've tried their solutions anyway (when relevant) and they haven't helped.</p>
  
  <p>I had created a JavaFX FXML Application in NetBeans 8.0.2 and had to manually upgrade the JDK from 1.7 to 1.8 to get features I wanted.  I believe I was using 1.8.0_52 for both the JRE and the JDK and the project was compiling fine.  Then my computer notified me of an update for Java 8. Now:</p>
  
  <pre><code>mc@MC-Desktop:~$ java -version
  java version "1.8.0_60"
  Java(TM) SE Runtime Environment (build 1.8.0_60-b27)
  Java HotSpot(TM) 64-Bit Server VM (build 25.60-b23, mixed mode)
  
  mc@MC-Desktop:~$ javac -version
  javac 1.8.0_60
  </code></pre>
  
  <p>and suddenly any Java 8 FXML project gets the above error message during compile-time, even the standard basic <code>JavaFX FXML Application</code> that comes with NetBeans. Java 7 FXML will compile but 7 is missing important features.  I've started new projects specifying 8 and I've started a new project in 7 and then upgraded it to 8: same result.</p>
  
  <p>I've ensured that the Source/Binary Format is JDK 8, in the Sources category and the Java Platform is set to JDK 1.8 in the Libraries category of the project's properties.  I can find no other setting to update.  I've tried a clean build each time I change a setting.  The error happens in an IDE-generated file <code>jfx-impl.xml</code> that is too large to post in its entirety, being over 4000 lines.  I post a portion here. The <code>classpath="${javafx.ant.classpath}"</code> is line 406, where the compiler reports the error:</p>
  
  <pre><code>&lt;target name="-check-ant-javafx-version" depends="-pre-check-ant-javafx-version,
          -set-endorsed-javafx-ant-classpath,-set-javafx-ant-classpath" if="do.check.ant-javafx.version"&gt;
      &lt;echo message="ant-javafx.jar.location = ${ant-javafx.jar.location}" level="verbose"/&gt;
      &lt;echo message="javafx.ant.classpath = ${javafx.ant.classpath}" level="verbose"/&gt;
      &lt;taskdef resource="com/sun/javafx/tools/ant/antlib.xml"
          uri="javafx:com.sun.javafx.tools.ant"
          classpath="${javafx.ant.classpath}"/&gt;
      &lt;condition property="have-fx-ant-init"&gt;
          &lt;typefound name="javafx:com.sun.javafx.tools.ant:init-ant"/&gt;
      &lt;/condition&gt;
      &lt;property name="ant-javafx-version-already-checked-in-jfximpl" value="true"/&gt;
      &lt;echo message="have-fx-ant-init = ${have-fx-ant-init}" level="verbose"/&gt;
  &lt;/target&gt;
  </code></pre>
  
  <p>The error message is:</p>
  
  <pre><code>/home/chris/Projects/Java/FXMLTimer/nbproject/jfx-impl.xml:3438: The following error occurred while executing this line:
  /home/chris/Projects/Java/FXMLTimer/nbproject/jfx-impl.xml:406: 
  java.lang.UnsupportedClassVersionError: com/sun/javafx/tools/ant/Permissions : Unsupported major.minor version 52.0
      at java.lang.ClassLoader.defineClass1(Native Method)
      at java.lang.ClassLoader.defineClass(ClassLoader.java:800)
      at org.apache.tools.ant.AntClassLoader.defineClassFromData(AntClassLoader.java:1136)
      at org.apache.tools.ant.AntClassLoader.getClassFromStream(AntClassLoader.java:1307)
      at org.apache.tools.ant.AntClassLoader.findClassInComponents(AntClassLoader.java:1362)
      at org.apache.tools.ant.AntClassLoader.findClass(AntClassLoader.java:1323)
      at org.apache.tools.ant.AntClassLoader.loadClass(AntClassLoader.java:1076)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
      at java.lang.Class.forName0(Native Method)
      at java.lang.Class.forName(Class.java:278)
      at org.apache.tools.ant.taskdefs.Definer.addDefinition(Definer.java:579)
      at org.apache.tools.ant.taskdefs.Definer.execute(Definer.java:237)
      at org.apache.tools.ant.taskdefs.Antlib.execute(Antlib.java:180)
      at org.apache.tools.ant.taskdefs.Definer.loadAntlib(Definer.java:428)
      at org.apache.tools.ant.taskdefs.Definer.execute(Definer.java:277)
      at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
      at sun.reflect.GeneratedMethodAccessor169.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
      at org.apache.tools.ant.Task.perform(Task.java:348)
      at org.apache.tools.ant.Target.execute(Target.java:435)
      at org.apache.tools.ant.Target.performTasks(Target.java:456)
      at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)
      at org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(SingleCheckExecutor.java:38)
      at org.apache.tools.ant.Project.executeTargets(Project.java:1248)
      at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:441)
      at org.apache.tools.ant.taskdefs.CallTarget.execute(CallTarget.java:105)
      at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
      at sun.reflect.GeneratedMethodAccessor169.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
      at org.apache.tools.ant.Task.perform(Task.java:348)
      at org.apache.tools.ant.Target.execute(Target.java:435)
      at org.apache.tools.ant.Target.performTasks(Target.java:456)
      at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)
      at org.apache.tools.ant.Project.executeTarget(Project.java:1364)
      at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
      at org.apache.tools.ant.Project.executeTargets(Project.java:1248)
      at org.apache.tools.ant.module.bridge.impl.BridgeImpl.run(BridgeImpl.java:286)
      at org.apache.tools.ant.module.run.TargetExecutor.run(TargetExecutor.java:555)
      at org.netbeans.core.execution.RunClassThread.run(RunClassThread.java:153)
  BUILD FAILED (total time: 7 seconds)
  </code></pre>
  
  <p>Does anyone have an idea what I'm missing?  Is there a bug in NetBeans or in the 1.8.0_60 SDK or JRE?  Thanks for your time &amp; consideration!</p>