Results 1 to 7 of 7
  1. #1
    manolis_kakou is offline Member
    Join Date
    Jun 2010
    Posts
    5
    Rep Power
    0

    Default How can I convert java files to exe?

    Hi! I have a problem...I want to convert java to exe files but I can not...I was trying to do with a program ''java launcher 3.201'' but I was failed...Do you have any idea? Please help me
    Thank you!

  2. #2
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    17,816
    Rep Power
    25

    Default

    No idea. I always use jar files.

  3. #3
    doWhile is offline Moderator
    Join Date
    Jul 2010
    Location
    California
    Posts
    1,641
    Rep Power
    7

    Default

    Quite a few apps out there to do this for you. JSmooth, Launch4j, etc...Just google. If you just want a double clickable file, just package it as an executable .jar

  4. #4
    JosAH's Avatar
    JosAH is online now Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,734
    Blog Entries
    7
    Rep Power
    21

    Default

    Quote Originally Posted by manolis_kakou View Post
    Hi! I have a problem...I want to convert java to exe files but I can not...I was trying to do with a program ''java launcher 3.201'' but I was failed...Do you have any idea? Please help me
    Thank you!
    But Java does produce machine code in the end; an ordinary compiler translates source code (e.g. C or C++) to machine code directly. The Java compiler (javac) produces 'byte code' which are machine code instructions for a hypothetical machine, the virtual machine. That virtual machine interprets the byte code but there is a largely misunderstood mechanism: the HotSpot mechanism and its JIT compiler (Just In Time). When the HotSpot mechanism detects that a piece of byte code is interpreted (slow) repeatedly, for instance the code that makes up the body of a loop, it calls the JIT compiler that translates the byte code to ordinary machine code (fast). If your Java program runs long enough the HotSpot mechanism has compiled all your byte code (virtual machine code) to real machine code. There is no need to produce real machine code in one step (see above). A benefit is that the machine code produced in two steps is often 'better' (mind the quotes) than the machine code produced in one step.

    kind regards,

    Jos

  5. #5
    PhQ's Avatar
    PhQ
    PhQ is offline Senior Member
    Join Date
    Mar 2010
    Location
    Lithuania
    Posts
    358
    Rep Power
    5

    Default

    Yes you can, you can download .bat to .exe converters, all you have to do is make a bat file to run you application.

  6. #6
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    17,816
    Rep Power
    25

    Default

    What does a .bat file have to do with creating a .exe file from a .java file?

  7. #7
    PhQ's Avatar
    PhQ
    PhQ is offline Senior Member
    Join Date
    Mar 2010
    Location
    Lithuania
    Posts
    358
    Rep Power
    5

    Default

    Quote Originally Posted by Norm View Post
    What does a .bat file have to do with creating a .exe file from a .java file?
    Oooh he meant from a JAVA file? I thought he wanted to run his application with a .exe.

Similar Threads

  1. Replies: 8
    Last Post: 07-30-2010, 06:47 PM
  2. conversion of java .class files to .java files
    By kotturupraveen in forum New To Java
    Replies: 2
    Last Post: 06-09-2008, 01:58 PM
  3. how to convert mpeg files to .wav files
    By christina in forum New To Java
    Replies: 1
    Last Post: 08-06-2007, 05:14 AM
  4. convert xls files into pdf files
    By bbq in forum New To Java
    Replies: 3
    Last Post: 07-20-2007, 04:56 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •