How to Create Executable jar file from .java file. Having only one java file dm.java which created using awt and applet. I need to create executable jar with icon or with im
It is possible to use Java Web Start to launch applets free-floating on the desk top. JWS can install desktop shortcuts & menu items for apps., both with icons.
JWS uses Jar files only. To Jar your applet, do something like..
prompt>dir
dm.java
prompt>javac dm.java // compile the source
prompt>dir
dm.class
dm$1.class
dm.java
prompt>jar -cf *.class dm.jar // archive the classes
prompt>dir
dm.class
dm$1.class
dm.jar
dm.java
prompt>
It is not strictly necessary to include a manifest in a JWS application, and there is almost no point for a JWS applet. The applet class is instead specified in the JNLP file used to launch the applet. The JNLP file also contains information on the shortcuts and icons.