开发者

Java Application executed from Desktop

I have made a jav开发者_StackOverflowa application in Eclipse and it has a Main class which has the main method from which the application runs. I want that i should be able to run the application from outside the eclipse maybe by clicking on some icon.

Can anyone guide how that might be possible?


  • Create a Java .exe/.jar file
  • Create JAR file in Java & Eclipse

JAR file using Eclipse IDE

  • Right click on your project, which you want to create a JAR file of. And select Export from the context menu.
  • Select JAR file from Java folder and click Next.
  • Provide the Destination path and click on Finish to create the JAR.


You should build the application first,then you'll find a file with the extension ".jar" in the project's directory

you can run this jar anywhere


Once you have a Jar, you might also deploy the app. using Java Web Start.

JWS can do desk-top integration tasks like providing a desktop icon (with customized icon) and/or menu item. JWS also offers many other nice features like configurable automatic update & file associations, and offers a comprehensive API that is only available to JWS apps. The JNLP API makes persistence, single instance code and other things easy.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜