Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > Executable jar

Reply
Thread Tools

Executable jar

 
 
jennifereden.price@gmail.com
Guest
Posts: n/a
 
      06-06-2006
Hi,

How can I distribute a java aplication as a .exe file? I've read about
executable jars, but those require either a command or the right
association for the jar files. I would like my small group of users to
simply be able to click an a .exe file or a .bat without an additional
installation. All of my users a guaranteed to have java installed on
their machines.

Thanks!

Aaron Fude

 
Reply With Quote
 
 
 
 
Jason in Colorado
Guest
Posts: n/a
 
      06-07-2006
For Windows, write a .bat file. You may want to look for the proper
JVM version and path on the client as well. The .bat file would issue
a java command at some point, probably with command line args, to fire
up the class with the main entry point.

Thats it.

On Solaris/Linux/Unix/BSD write a shell script.

> How can I distribute a java aplication as a .exe file?


 
Reply With Quote
 
 
 
 
Luc The Perverse
Guest
Posts: n/a
 
      06-07-2006
<(E-Mail Removed)> wrote in message
news:(E-Mail Removed) oups.com...
> Hi,
>
> How can I distribute a java aplication as a .exe file? I've read about
> executable jars, but those require either a command or the right
> association for the jar files. I would like my small group of users to
> simply be able to click an a .exe file or a .bat without an additional
> installation. All of my users a guaranteed to have java installed on
> their machines.


I'm not sure you are asking the right question.

Are you sure you want the jar file to be clickable, or do you just want a
convenient method for running the program?

I suggest using an installation program which can create quicklaunch,
desktop and or start menu shortcuts. These can invoke the JAR file through
either java.exe or javaw.exe, whichever is appropriate for your application.

Putting a BAT file with your JAR file will make it much easier to be run -
but most people do not have winrar installed on their system - this is the
only decompression program I know of that by default will steal the JAR file
association from Sun. On windows jar file double clicking after
installation of JRE will invoke the program contained therein.

--
LTP




 
Reply With Quote
 
Lee Weiner
Guest
Posts: n/a
 
      06-07-2006
In article <(E-Mail Removed) .com>, http://www.velocityreviews.com/forums/(E-Mail Removed) wrote:
>Hi,
>
>How can I distribute a java aplication as a .exe file? I've read about
>executable jars, but those require either a command or the right
>association for the jar files. I would like my small group of users to
>simply be able to click an a .exe file or a .bat without an additional
>installation. All of my users a guaranteed to have java installed on
>their machines.


If all your users have Java installed, then the file association already
exists. The installation of the JRE creates the file association in the
registry. You simply put a shortcut to the jar file on the desktop or menu
system and click it.

Lee Weiner
lee AT leeweiner DOT org
 
Reply With Quote
 
Andrew T.
Guest
Posts: n/a
 
      06-07-2006

(E-Mail Removed) wrote:
...
> ... I would like my small group of users to
> simply be able to click an a .exe file or a .bat without an additional
> installation. All of my users a guaranteed to have java installed on
> their machines.


JWS (Java WebStart) is the easiest for end users.

HTH

Andrew T.

 
Reply With Quote
 
Luc The Perverse
Guest
Posts: n/a
 
      06-07-2006
"Andrew T." <(E-Mail Removed)> wrote in message
news:(E-Mail Removed) oups.com...
>
> (E-Mail Removed) wrote:
> ..
>> ... I would like my small group of users to
>> simply be able to click an a .exe file or a .bat without an additional
>> installation. All of my users a guaranteed to have java installed on
>> their machines.

>
> JWS (Java WebStart) is the easiest for end users.
>


But has some downsides

--
LTP




 
Reply With Quote
 
Steve Sobol
Guest
Posts: n/a
 
      06-07-2006
(E-Mail Removed) wrote:

> How can I distribute a java aplication as a .exe file? I've read about
> executable jars, but those require either a command or the right
> association for the jar files. I would like my small group of users to
> simply be able to click an a .exe file or a .bat without an additional
> installation. All of my users a guaranteed to have java installed on
> their machines.


http://launch4j.sf.net/

works quite well, has lots of options including a splash screen option, and
is open-source.

--
Steve Sobol, Professional Geek ** Java/VB/VC/PHP/Perl ** Linux/*BSD/Windows
Apple Valley, California PGP:0xE3AE35ED

It's all fun and games until someone starts a bonfire in the living room.
 
Reply With Quote
 
TechBookReport
Guest
Posts: n/a
 
      06-07-2006
(E-Mail Removed) wrote:
> Hi,
>
> How can I distribute a java aplication as a .exe file? I've read about
> executable jars, but those require either a command or the right
> association for the jar files. I would like my small group of users to
> simply be able to click an a .exe file or a .bat without an additional
> installation. All of my users a guaranteed to have java installed on
> their machines.
>
> Thanks!
>
> Aaron Fude
>


You might want to take a look at jSmooth: http://jsmooth.sourceforge.net/

--
TechBookReport Java http://www.techbookreport.com/JavaIndex.html
 
Reply With Quote
 
dimitar
Guest
Posts: n/a
 
      06-07-2006
Luc The Perverse wrote:
> But has some downsides


I'm willing to hear about these.
Can anybody recommend another 1 click deployment tool for Java?

I have an app which I consider to migrate to Webstart. It's already
packaged in signed jars and requires the following permissions:

- establish a few socket connections.
- read/write to user's preference store.
- write to temp file system.
- load native code (the SWT libraries).

Right now the user has to download a package, unzip it in an empty
directory and click on the right file. The target scenario is that an
user would receive a link in his email, click it and the application
will start, adding a new icon in his start menu as well.

Dimitar

 
Reply With Quote
 
Luc The Perverse
Guest
Posts: n/a
 
      06-07-2006
"dimitar" <(E-Mail Removed)> wrote in message
news:kdzhg.130$(E-Mail Removed)...
> Luc The Perverse wrote:
>> But has some downsides

>
> I'm willing to hear about these.


http://mindprod.com/jgloss/javawebstart.html

--
LTP




 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Running an Executable Before Executable JAR Jason Cavett Java 8 05-16-2007 07:14 PM
java -cp a.jar -jar b.jar => Works on Windows, not on Debian cyberco Java 4 02-14-2006 06:27 AM
jaas.jar, jta.jar jdbc-stdext.jar missing from jdk1.5 RPM muttley Java 0 10-20-2005 02:40 PM
Differences of xercesImpl.jar, xercesImpl-J.jar, dom3-xercesImpl.jar ? Arnold Peters Java 0 01-05-2005 10:59 PM
Differences of xercesImpl.jar, xercesImpl-J.jar, dom3-xercesImpl.jar ? Arnold Peters XML 0 01-05-2005 10:59 PM



Advertisments