No Class File Found For Application Even Though It Exists

XMLWordPrintable

    • Type: Bug
    • Resolution: Won't Fix
    • Priority: P4
    • fx2.0
    • Affects Version/s: None
    • Component/s: deploy
    • None
    • Environment:

      Windows XP, JDK 6u24, JavaFX 2 (build 17), Visage

      After running a JavaFX 2.0 application the following is displayed in the console:


      Exception in thread "main" java.lang.NoClassDefFoundError: javafx/application/application
              at java.lang.ClassLoader.defineClass1(Native Method)
              at java.lang.ClassLoader.defineClassCond(Unknown Source)
              at java.lang.ClassLoader.defineClass(Unknown Source)
              at java.security.SecureClassLoader.defineClass(Unknown Source)
              at java.net.URLClassLoader.defineClass(Unknown Source)
              at java.net.URLClassLoader.access$000(Unknown Source)
              at java.net.URLClassLoader$1.run(Unknown Source)
              at java.security.AccessController.doPrivileged(Native Method)
              at java.net.URLClassLoader.findClass(Unknown Source)
              at java.lang.ClassLoader.loadClass(Unknown Source)
              at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
              at java.lang.ClassLoader.loadClass(Unknown Source)
              at org.nick.addressbook.AddressBook.main(AddressBook.java:8)
      Caused by: java.lang.ClassNotFoundException: javafx.application.Application
              at java.net.URLClassLoader$1.run(Unknown Source)
              at java.security.AccessController.doPrivileged(Native Method)
              at java.net.URLClassLoader.findClass(Unknown Source)
              at java.lang.ClassLoader.loadClass(Unknown Source)
              at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
              at java.lang.ClassLoader.loadClass(Unknown Source)
              ... 13 more


      The NoClassDefFoundError occurs on this line below:

          Launcher.launch(Lifecycle.class, null);

      This problem did not occur with an earlier build of JavaFX 2 (build 13). In the manifest jfxrt.jar is included in the class-path property, and the required file does contain the required class file. If the file wasn't referenced then a different error would be occuring. I have noticed that the size of jfxrt.jar in both JavaFX builds (13 and 17) is exactly the same, is that supposed to be the case?

            Assignee:
            Thomas Ng (Inactive)
            Reporter:
            Nick Apperley (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported: