• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Generate an exe file?

 
Gurukant Desai
Greenhorn
Posts: 2
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How to convert java programs to windows .exe files using eclipse?
How are the applications such as Azureus, limewire etc packaged into an exe installer?
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 33671
316
Eclipse IDE Java VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There are a number of programs that compile Java into a Windows exe.
 
Campbell Ritchie
Sheriff
Pie
Posts: 47228
52
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am not sure you either can or want to create .exe files.
What you do is to create an executable .jar file.
If I remember correctly, this is how you do it in Eclipse:
  • Right-click the name of the project in the left pane.
  • Click export
  • In the new window click the arrowhead near "Java" so expand the list.
  • Click ".JAR file"
  • Click "Next"
  • Enter a name for the .jar file
  • Click "next" twice.
  • Put the name of the class with the main method in the box.
  • Click finish.
  • Find the .jar file.
  • Copy a shortcut to it onto the Windows desktop.
  • If your file associations are set up properly, then you can run the application by double-clicking he desktop icon.
  • If you need to add other files to your classpath, search through this forum and find my earlier posts about adding to the classpath.
     
    Paul Clapham
    Sheriff
    Pie
    Posts: 20163
    24
    MySQL Database
    • 0
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    Also, just because those applications use a Windows installer to get themselves loaded onto Windows machines, it doesn't follow that the result of the installation is a Windows exe file. If you want to get your application installed on other people's Windows machines, I definitely recommend using a Windows installer to do that. But I don't recommend using those applications that convert your application into a standalone exe file. They usually aren't necessary and often people seize upon them because they don't realize that they can use a standard Windows installer instead.
     
    • Post Reply
    • Bookmark Topic Watch Topic
    • New Topic