File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Java in General and the fly likes How to create executable java files( jar ) Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "How to create executable java files( jar )" Watch "How to create executable java files( jar )" New topic

How to create executable java files( jar )

nagaraj reddy
Ranch Hand

Joined: Feb 21, 2005
Posts: 43
How can we create executable jar files in java.
Lionel Badiou
Ranch Hand

Joined: Jan 06, 2005
Posts: 140
Hi Nag,

Look here. You may have found the anwser by yourself using google


Lionel Badiou
CodeFutures Software
Ilja Preuss

Joined: Jul 11, 2001
Posts: 14112
Moving to Java in General (intermediate)...

The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
Igor Stojanovic
Ranch Hand

Joined: Feb 18, 2005
Posts: 58
Hi nag,

check these 3 links, they might help you in application deploying:

1.JSmooth is a Java Executable Wrapper that makes a standard Windows executable binary (.exe) from a jar file. It makes java deployment much smoother and user-friendly, as it is able to find a Java VM by itself. When no VM is available, it provides feed-back to the users, and can launch the default web browser to an URL that explains how to download a Java VM.
Jsmooth is free software released under the terms of the GNU General Public License.

2.Inno Setup is a free installer for Windows programs. First introduced in 1997, Inno Setup today rivals and even surpasses many commercial installers in feature set and stability.

3.Java launcher is an easy-to-use software which contains four features:

Run Java applications and applets by double-clicking class files in Windows explorer
as if they are normal Windows executable files.
at same time, the software can check class errors (such as package error) and monitor streams for Java exceptions.

Launch Java source code and class hierarchy by right-clicking class files from Windows explorer
class files are not restricted to application and applet classes, they can be any.
class hierarchy is in graphic format, which can check Java errors for you

Create Windows exe files
the software compresses all class and other files (such as image files) into a single exe file.
the exe file can be launched by double-click in Windows Explorer as if it is a normal Windows executable file.
user icon, arguments of Java method main(), system and user classpaths can be added to the exe file.
You can distribute the single exe file to your customers without other files.

Create executable jar files
the jar files are compressed from all class and related files and compatible with multiple platforms.
you can launch Java application by double-click the jar files if using Windows.

kind regards
[ February 21, 2005: Message edited by: Igor Stojanovic ]
Marilyn de Queiroz

Joined: Jul 22, 2000
Posts: 9058
I suggest you read the Javaranch FAQ. You just asked question number 16.

"Yesterday is history, tomorrow is a mystery, and today is a gift; that's why they call it the present." Eleanor Roosevelt
Lionel Badiou
Ranch Hand

Joined: Jan 06, 2005
Posts: 140

Just a note to Igor's suggestions. As far as deploying is concerned, you migh also consider using this free installer.

Among other things, it can package your application with a VM that may be installed by the end user, it runs on all platform and can also generate a web installer (automatic installation from a website).

Best regards,
Igor Stojanovic
Ranch Hand

Joined: Feb 18, 2005
Posts: 58
Thank you Lionel

kind regards
I agree. Here's the link:
subject: How to create executable java files( jar )
It's not a secret anymore!