carljmosca
2012-07-20 19:29:10 UTC
I have been working with a JavaFX project in NetBeans. The project is in maven format and utilizes the javafxpackager. It is a combination of a few examples I have been able to find on the web.
When I run the program from within NetBeans I get an error which I believe indicates the JavaFX runtime jar is not available:
Exception in thread "main" java.lang.NoClassDefFoundError: javafx/application/Application
I have tried changing the outputDirectory of the jar files. I was under the impression that this is a JavaFX/maven issue but I now think it's a NetBeans problem (or a problem with how I have configured a NB project). In the current state, the jar files are copied to the target directory (instead of the default target/dependency directory).
I am able to run this project via the command line:
java -jar JFXMavenPkgExample.jar (from the target directory)
I have tried changing the parameters on the run action to include the classpath (before and after I changed the outputDirectory in the configuration of the maven-dependency-plugin) but so far I have not had success.
The project is now on github: https://github.com/carljmosca/JFXMavenPkgExample
because I would like to share a complete working example once I get there. :)
TIA,
Carl
When I run the program from within NetBeans I get an error which I believe indicates the JavaFX runtime jar is not available:
Exception in thread "main" java.lang.NoClassDefFoundError: javafx/application/Application
I have tried changing the outputDirectory of the jar files. I was under the impression that this is a JavaFX/maven issue but I now think it's a NetBeans problem (or a problem with how I have configured a NB project). In the current state, the jar files are copied to the target directory (instead of the default target/dependency directory).
I am able to run this project via the command line:
java -jar JFXMavenPkgExample.jar (from the target directory)
I have tried changing the parameters on the run action to include the classpath (before and after I changed the outputDirectory in the configuration of the maven-dependency-plugin) but so far I have not had success.
The project is now on github: https://github.com/carljmosca/JFXMavenPkgExample
because I would like to share a complete working example once I get there. :)
TIA,
Carl