简体   繁体   中英

Runnable JAR exe wrapper and JRE installer if not exist

I have created Java Swing application that i have exporter to runnable jar file. With the use of Launch4j ( link ) i have managed to wrap it in exe file. If JRE not installed on the PC it sends the user to JAVA site to download. My question if there any wrapper that installs JRE automatically without sending the user to site.

I used launch4j to deploy a swing app like this too. I just put the JRE folder into the same folder as my exe and jar file. You can deploy a JRE with your application just in case you need to ensure it has the version it needs. So my application has its own folder with a JRE folder in it, other jar files my app uses, the exe and ini file for launch4j. I cannot remember if I told launch4j to use the JRE in that folder or not, but it has to know to use that local JRE.

Here's a link to another question where someone did the same thing and tell how they pointed to the JRE. Specify JRE in launch4j

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM