473,569 Members | 2,472 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

how to create .exe file in java

1 New Member
I was created a software using frame so i want to create a executable file for the software.please tell me how to craete a .exe file for the java software?
Oct 18 '09 #1
2 2386
Dököll
2,364 Recognized Expert Top Contributor
You will need a .WAR file for certain Windows Apps, .WAR or .EAR should do the trick most ofthe time for either that or Web Apps. Please forgive me I am not aware of .exe files for Java Apps.

Good luck!
Nov 9 '09 #2
chaarmann
785 Recognized Expert Contributor
The *.exe file is only machine language for dos/windows and can only run there. But Java runs on all operating systems, so it's using an intermediate code (which will be processed by the JVM and JIT). In the old days we used Symantec Visual Cafe to compile Java programs directly in machine language (.exe) or used MS Visual J++, but gladly these days are over, you don't need to do it anymore! JIT-compilers are so fast nowadays that portability is more important.

To distibute or run your java program as only one file, you don't need an *.exe. You can make a single *.jar file from all your classes.
So you can double-click the *.jar and it runs like an *.exe (if you have not modified the file associations, for example to open it with WinZip)!
To run it in this case, just create an icon (or a *.bat text file) with the command inside
Expand|Select|Wrap|Line Numbers
  1. java -jar myApp.jar
Or more precisely, and also if you do not like console window (you wrote that your program already has a frame):
Expand|Select|Wrap|Line Numbers
  1. C:\Programs\myJavaInstallationFolder\bin\javaw.exe -jar "C:\Programs\myAppFolder\myApp.jar"
Nov 9 '09 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

0
3654
by: Jagdeesh | last post by:
Hai Colleagues, I am using Tomcat 4.1.24 and JDK 1.4.0_03 in my winXP machine. I've transferred a set of folders(containing jsp files) into tomcat's webapps directory(to /webapps/bob , /webapps/sue) and i have added the folders bob, sue in my server.xml(in the context path). When i am trying to run jsp files from my browser, it works...
1
2621
by: D. Lee Christopher | last post by:
Can anyone point me to a good tutorial for creating a site-level search applet? I am trying to create a virtual catalog of sorts, and I would like to be able to search the catalog and have the results displayed on the same page with one column text and an image of the product. I've seen several tutorials that create site-level searches that...
9
3540
by: Albretch | last post by:
.. I am trying to create a database in a MS Access DB via JDBC drivers. I have tried both sun.jdbc.odbc.JdbcOdbcDriver and ids.sql.IDSDriver From some reason both drivers Exceptions tell me 'Syntax error in CREATE TABLE statement' even though I am not creating a table, but a Database // - - - - - - - - - - - - sun.jdbc.odbc.JdbcOdbc...
3
2181
by: Dhananjayan | last post by:
Hi, I have a java webservice running on Axis, Iam able to create a java client to invoke the webservice and obtain the result. But iam not able to invoke the service from .Net client.. Here are the steps i followed to create a .net client I created a web reference("NetClient") for a webservice running in Axis thru "Add Web Reference", it...
0
1945
by: gopikrishnan | last post by:
Hi to all, i am developing a java project which workes in linux. I need to create a Word document through my java program, rep_path = --FIlePath-- fso = new File(rep_path); if (! (report_nmdb != null && fso.exists()) ) { fso.createNewFile(); // creating documnet file in rep_path }
0
1988
by: Husey | last post by:
Hi, I am trying to create a very simple EJB project which requires me to create a new jboss configuration in Eclipse. I keep getting the error message "An error has occurred. See error log for more details". Same for all versions of JBoss. I couldn't find what causes the error. Any help would be much appreciated. My installation is: JDK...
4
2799
by: Benny Dein | last post by:
Hi I want to create a servlet or something similar by which im able to create virtual webservices. Lets say i would like to create a webservice with a method called 'getDate' which returnes the current date. This could be done by making a wsdl file (or whatever the name is) and via a wizard in some java tool make a real webservice. This...
1
4447
by: henrymania | last post by:
Am writing a code for database backup....by backupservlet is as given below i get the following exception
3
1775
by: fazilhussain | last post by:
i tried to create an object of a class created with a different file and it worked. But when i try to create the object after packaging it didnt compile. why is that? pls if u know the correct reason email me or post here (XXX@XXX) WORKED CODES...... //A.java class A{ A(){ B b=new B(); }// const end
0
3720
by: TrevRex | last post by:
Hello, I work for a non-profit in San Diego as a GIS Specialist. I have had to teach myself about some scripting to create some dynamic maps, but I am still very limited in my skills, so I have had to explore the internet in order to discover various tutorials and examples that have led me on a positive path. Right now I am working on a...
0
7703
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7618
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
8132
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
0
7982
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6286
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
1
5514
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
3656
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3644
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
944
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.