473,406 Members | 2,698 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

to create exe file

Could anyone gimme some inputs on how to create an exe file?
This exe program is a counter to count how many of something - let's say
"hello world" in a text file? Kindly please share some tips with me..
Thank you in advance
Jun 3 '07 #1
9 2747
JosAH
11,448 Expert 8TB
Could anyone gimme some inputs on how to create an exe file?
This exe program is a counter to count how many of something - let's say
"hello world" in a text file? Kindly please share some tips with me..
Thank you in advance
What do you need an .exe file for? Java uses executable .jar files for that purpose.

kind regards,

Jos
Jun 3 '07 #2
What do you need an .exe file for? Java uses executable .jar files for that purpose.

kind regards,

Jos
To count words in a text file.
So I just need to click on the exe file to start counting.....
Now I need to compile my application to jar ? thank you
Jun 3 '07 #3
JosAH
11,448 Expert 8TB
To count words in a text file.
So I just need to click on the exe file to start counting.....
Now I need to compile my application to jar ? thank you
You don't "compile to a jar". The jar tool is just like winzip: you compile your
.java files to .class files as always and you bundle (and optionally compress)
those .class files in a .jar file using the jar tool. You add a little "manifest" file
to that jar. The manifest file tells the JVM what class to look for that contains
the public static void main method. You can simply click on your .jar file to
execute it.

Read all about it in the Jar Documentation.

kind regards,

Jos
Jun 3 '07 #4
hafij
1
How can i create an exe from jar
Jul 9 '07 #5
odefta
18
It is possible to create an exe file from a java .class

Make a shortcut - a create shortcut window appears... in 'type the location of the item textbox' insert the javaw command to point to the java class.
For example: javaw Test.class

Type next. A windows exe file will be created!

Good luck
Jul 9 '07 #6
It is possible to create an exe file from a java .class

Make a shortcut - a create shortcut window appears... in 'type the location of the item textbox' insert the javaw command to point to the java class.
For example: javaw Test.class

Type next. A windows exe file will be created!

Good luck
HI .. i tried creating the shortcut , the .exe file was created alright , but when i tried opening it , there was an error message :


JAVA VIRTUAL MACHINE LAUNCHER :
could not find the main class . program will exit.

what could be the reason??? could u plssss help me , i want my project to run like software ..
thanx
Oct 28 '07 #7
JosAH
11,448 Expert 8TB
HI .. i tried creating the shortcut , the .exe file was created alright , but when i tried opening it , there was an error message :


JAVA VIRTUAL MACHINE LAUNCHER :
could not find the main class . program will exit.

what could be the reason??? could u plssss help me , i want my project to run like software ..
thanx
Read the link I supplied in reply #4; there is absolutely no need to create .exe
files or whatever. A simple executable .jar file is enough. Anything else is just
an ugly hack that doesn't even run on other platforms.

kind regards,

Jos
Oct 28 '07 #8
heat84
118 100+
when you have created your jar file , there is software called jar2exe which will convert the jar file to exe , however , the jar files may be sufficient without being converted to .exe files.
Nov 12 '07 #9
JosAH
11,448 Expert 8TB
when you have created your jar file , there is software called jar2exe which will convert the jar file to exe , however , the jar files may be sufficient without being converted to .exe files.
Any of such 'jar2exe' utilities are just dumb platform dependent hacks; they won't
work on anything non-MSWindows. There's no need to use them at all. Jar files
are fine, if only people would care to read instructions and know how to use the
single jar utility: platfrom independent and your java code would always work.

kind regards,

Jos
Nov 12 '07 #10

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

Similar topics

4
by: Frank Millman | last post by:
Hi all I need to generate potentially large reports from a database, and I want to offer the option of print preview before actually printing (using wxPython). I figure that the best way to...
7
by: dog | last post by:
I've seen plenty of articles on this topic but none of them have been able to solve my problem. I am working with an Access 97 database on an NT4.0 machine, which has many Access reports. I...
4
by: I_AM_DON_AND_YOU? | last post by:
There is one more problem I am facing but didn't get the solution. In my Setup Program I am not been able to create 2 things (when the program is intalled on the client machine ) : (1) create...
5
by: Michael Sperlle | last post by:
Is it possible? Bestcrypt can supposedly be set up on linux, but it seems to need changes to the kernel before it can be installed, and I have no intention of going through whatever hell that would...
8
by: barb | last post by:
So that the world at large benefits from our efforts, here is one fully documented way to use Windows Irfanview freeware to create thumbnail web galleries (http://www.irfanview.com). STEP 1:...
23
by: sandy | last post by:
I need (okay, I want) to make a dynamic array of my class 'Directory', within my class Directory (Can you already smell disaster?) Each Directory can have subdirectories so I thought to put these...
4
by: Vlad | last post by:
I am having problems using the file.create method within a function that is called when looping through an array of filepaths. If I call my function with a hardcoded file path --C:\Temp.txt the...
3
by: sanghavi | last post by:
how to create a set up project in vb.net..how to run an application on a different machine
3
by: brook | last post by:
hey all - i´m new to php and having trouble writing a simple code which should create a file. here is the most simplified version: <?php $content = "my content"; $path = "test.txt";...
15
by: lxyone | last post by:
Using a flat file containing table names, fields, values whats the best way of creating html pages? I want control over the html pages ie 1. layout 2. what data to show 3. what controls to...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
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...
0
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,...
0
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...

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.