Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Java on CD-ROM

 
Vinnie Jenks
Ranch Hand
Posts: 207
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My company is creating a CD-ROM they'll be sending out to all of their customers. On it they would like to include a simple calculator for their products that has a simple database back-end (read-only).

How can I package a Java app, say, using Swing, on a CD-ROM to where the users would not have to install the JRE (it would be on the CD)?

In other words, how can I make a jar or another type of executable that can be clicked-and-run directly from the CD-ROM...how would I make a call to the local JRE on the CD?

Thanks!
 
Jeff Bosch
Ranch Hand
Posts: 805
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I would create a batch file to run from the local JRE. If the batch file is on the root directory of the CD, the java.exe is in a jre/bin folder, and the app is in an app/ folder, and it's in a jar called app.jar, you could do something like the following in the bat file:

/jre/bin/java.exe -jar app/app.jar


Hope that helps.
 
Don't get me started about those stupid light bulbs.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic