Reputation: 58786
I wish to give some demo copies of a Java application on a DVD to a client. Does it make sense to have a preinstalled JRE and Java application on a DVD so that they can just click and run it?
Also, if anyone has done this what are your views on this?
Upvotes: 14
Views: 1409
Reputation: 168825
If:
..I would recommend using deployJava.js to ensure a suitable minimum JRE, & Java Web Start to download/install & launch the demos.
JWS has a number of advantages in this situation:
You might include an HTML page on the CD (DVD would be a waste for a single HTML, a couple of images & some CSS based style sheets) that links to the demos. But since the hardest thing about getting a user to try a demo. is getting them to put the disk in the drive, I would side-step the disk entirely & send the 'Here are some free demos.' HTML to the user as email.
This was included as a comment a couple of days ago. Since the thread was resurrected, I decided to include it as an answer & expand on it.
Upvotes: 2
Reputation: 2795
Indeed you can simply put a JRE into a directory of the DVD.
Then you start the application with a .bat
file that runs a command such as :
jre\bin\java.exe -jar Main.jar
(If your jar and the jre folder are in the same directory)
Be careful about one thing : you can't know in advance what the DVD's drive letter will be, so in your .bat
file you must give relative paths to the JRE and to your jar (or starting class).
Upvotes: 9
Reputation: 8204
I would suggest you skip the DVD and go for a flash drive instead. This way you can use portable Java and run your app from the flash drive without having to install anything on your client's computer. With the low costs of flash drives these days you should easily earn back what you spend in money in convenience and time.
Here is a tutorial that shows you how to set this up.
Upvotes: 14
Reputation: 37027
I've in the past copied a windows JRE directory to a USB flash drive, and run a java app off that.
Upvotes: 2
Reputation: 23629
If you are dealing with a one or two people then just throw a JRE on the DVD and explain how to install it or even just include a link to the page where they can install Java themselves. In the past when dealing with a large set of recipients that needed to install a JRE and run an application, I have used tools like InstallAnywhere, to create a simple setup to walk the user through a wizard for setup.
Upvotes: 4