The following article uses options that are available starting with the For Java edition and project type.
This tutorial will present in detail how to achieve this goal. In order to replicate it on your own machine, you need to have a Sun JDK installed (the latest version is recommended).
- 1. Create project
- 2. Enter Product Details
- 3. Add Installation Files
- 4. Define Java Products
- 5. Create program shortcut
- 6. Build
- 7. Run, test and remove
- 8. Video tutorial
- 9. See also
First you must download and unzip the Java Product Example. It contains all the files necessary to finish this tutorial, including a sample Advanced Installer project.
Let's say that we want to create a Windows Installer package for the included Java Product example. Start Advanced Installer and choose “Java” > “Java Application” as the project type.
A good idea is to save and name the project at this point. Use the “Save” menu item under the “File” menu or the Ctrl+S keyboard shortcut and let's name it JavaProductExample.aip.
Note that these details are completely fictive.
Go to the Files and Folders page by clicking on “Files and Folders” on the left side page menu.
Click on thetoolbar button. Browse to where your downloaded the example folder, then select DemoJar.jar file and click .
Go to the Java Products page by clicking on “Java Products” on the left pane.
Create a new Java Product by clicking on thetoolbar button. Let's call it Java Product Example.
In the "Settings" tab, click on the OK.button and select the DemoJar.jar file and click
Edit the Main class to: DemoMainClass
Go to "Virtual Machine" tab and set the JVM parameters:
- Initial heap size - 64 MegaBytes
- Maximum heap size - 256 MegaBytes
Specify the JRE version min and max to whatever version you have installed on your machine.
You can set the parameters by clicking on [...] button from the JVM Parameters field this way accessing the Edit Java Virtual Machine Parameters Dialog.
Back in the "Settings" tab select GUI Application. Optionally set a splash screen for your java product.
Now a new file has appeared in the Files and Folders Page: Java Product Example.exe.
Go to the Files and Folders page by clicking on “Files and Folders” on the left pane.
Select the Java Product Example.exe file and click on the OK.toolbar button. Set the description to: Java Product Example Application. Find yourself a nice icon on your computer. Click
Click on thetoolbar button.
Click on thetoolbar button to run and test the MSI you created. After installation you should have a Java Product Example folder in your “Start” menu. Run the application by selecting Java Product Example.
To remove the installed package, simply Run it again and select Remove.