2

I have made a desktop application in Java (using JDBC and Swing) using Eclipse. I want to make a shortcut to this application (an icon). When the icon is double clicked, the application will run.

How to do it?

Mark Rotteveel
  • 100,966
  • 191
  • 140
  • 197
Praful
  • 43
  • 2
  • 6

3 Answers3

4

Deploy the app. using Java Web Start. Not only does it have a simple system for installing desk-top and menu item shortcuts (on supported OS) for an app. with icons, but also offers the IntegrationService that allows the shortcuts to be examined/installed programmatically.

For more details see this answer. The 2 icons on the right hand side (JotPad & StarZoom) were installed by JWS.

Community
  • 1
  • 1
Andrew Thompson
  • 168,117
  • 40
  • 217
  • 433
1

Make the shortcut/icon execute your application:

java -jar yourApplication.jar org.example.your.MainClass
0

If it is a web application - Go to Desktop + Right Click + Select New Option + Select Shortcut option + Specify your path in the location field + Click Next + Type the shortcut name + Finish.

So, now you can view your application as a desktop shortcut and if you click on it, it will automatically load your web application on one click. Then you can change the Shortcut Icons in properties.

Thank you.

cryptic_star
  • 1,863
  • 3
  • 26
  • 47
Milind
  • 1
  • 1