java - SWT, packaging jar -


I have made a simple jar for my java-application (with SWT). In Netbeen, it starts to be normal, because it should be. But when I java -jar [jarName] so I'm starting with me this error:

  Java Vrgarnamkjr "thread" main " exceptions in Java .lang.NoClassDefFoundError: due to org / Eclipse / SWT / widgets / Composite roxed.Main.main (Main.java:15): org.eclipse.swt.widgets.Composite: java on java.net. lang.ClassNotFoundException. $ 1.run on java.net.URLClassLoader.findClass (URLClassLoader.java:190) java.security.AccessController.doPrivileged on java.lang.ClassLoader.loadClass (Native method) (URLClassLoader.java:202 ) (ClassLoader.java URLClassLoader: 307) sun.misc.Launcher $ AppClassLoader.loadClass (Launcher.java:301) on java.lang.ClassLoader.loadClass (ClassLoader.java:248). ..and 1 and   

I downloaded SWT from the pack jar (linux creation) and added this folder to the project.

Say to someone, the reason could be that I can not carry on this IDE?

update

swt.jar need META-INF / MANIFEST.MF to be linked with the entry class-path file Could.

You can read about the Java Launcher options on this.

Comments