Auto startup for java desktop application?

爱⌒轻易说出口 提交于 2019-11-26 23:17:20

问题


I have created a desktop application in Java using NetBeans 6.1 and made a jar file of the application. Now I want to make it automatically start up whenever a client's machine boots up.

How do I do that?


回答1:


There are many commercial installers which can do this http://www.advancedinstaller.com/jre-install.html

Are you looking for a free/OS one?

Thanks Krishna




回答2:


This installer can create a file with "msi" extension that will behave as regular windows installer. It bundles your jar file and JRE together into single file. The program acts as a "wizard", where you configure all necessary options.

Take a look at this product:Advanced Installer

Good luck.




回答3:


If you simply want to have a java application autostarted in Windows you could just create a link in the users autostart folder calling javaw the same way you'd normally call java.

This is just meant FYI, the other suggestions are more general, of course, but this could be the simplest solution...




回答4:


҉ works

I have found the following order best suite to take a decision for commercial or free one, to fit your needs (most of the following does auto startup + extra features):

Order show more features on top:

  1. BitRock: see features i would really use this one, because it does all cross platform + Jnlp + Prerequisite

  2. Tanukio: enter link description here

  3. IzPack

  4. Advancedinstaller: features

  5. (optional) Jnlp web start: example (this should become future way of installing)

Please note that, prerequisite is not mentioned, most of there feature list, which is very important to have in all of them, because many case we use third party libraries/dependencies, so the best question would be to know if they support it or not.




回答5:


Take a look at Tanuki's Java Service Wrapper. The Community version does what you need, plus a lot more.

If you only need to run a Java program periodically, I like pycron, which installs itself as a Windows service and then reads a Unix style crontab file where you would enter a line that tells pycron when it needs to run the java process (eg, every night at 3am).



来源:https://stackoverflow.com/questions/979451/auto-startup-for-java-desktop-application

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!