Results 1 to 14 of 14
  1. #1
    castiel is offline Member
    Join Date
    Aug 2009
    Posts
    26
    Rep Power
    0

    Default Create Executable problem

    Hey I've written a small game program with swing in Eclipse and I created a jar file with the program too. Now when I double click on the jar file it runs the game which is good. I copied the jar file to my usb and tried to see if it would work on my dad's computer and it did. But when I took the file to my friends place the jar file had turned into a winrar file and I couldn't run it. How come it has changed? I really want to make this a simple .exe file so I can give the game to my friends and they can all play it but how do I do this. I've googled this but it's been very confusing.

    Thanks

  2. #2
    m00nchile is offline Senior Member
    Join Date
    Feb 2010
    Location
    Ljubljana, Slovenia
    Posts
    470
    Rep Power
    5

    Default

    Two things are possible, either your friend doesn't have JRE installed, or he has installed JRE, but changed the default program to open .jar files from java to winrar.

  3. #3
    r035198x is offline Senior Member
    Join Date
    Aug 2009
    Posts
    2,388
    Rep Power
    8

    Default

    If you make it a .exe then only your windows friends can use it.

  4. #4
    castiel is offline Member
    Join Date
    Aug 2009
    Posts
    26
    Rep Power
    0

    Default Could you please give me some simple advice to create .exe

    The friends that I wanted to give the game to have Windows XP and Windows Vista so that is fine. So if you wouldn't mind either explaining the steps I need to take to create the .exe file or perhaps provide me with a good link I would really appreciate it.

    Cheers

  5. #5
    r035198x is offline Senior Member
    Join Date
    Aug 2009
    Posts
    2,388
    Rep Power
    8

    Default

    Creating a.exe is not going to automatically make the JRE available on their computer.
    It is still going to be needed so rather stick to the more portable jar file.
    If you insist on creating the .exe then you can google the many tools that are available for the conversion and read their manuals.

  6. #6
    castiel is offline Member
    Join Date
    Aug 2009
    Posts
    26
    Rep Power
    0

    Default

    Could you give me the link to which JRE to get my friend to download, there seem to be quite a lot of options. i was looking at this page Java SE Downloads - Sun Developer Network (SDN)
    but not sure if that's what i need? thanks 4 the help

  7. #7
    r035198x is offline Senior Member
    Join Date
    Aug 2009
    Posts
    2,388
    Rep Power
    8

    Default

    Hover your mouse over the underlined JRE link to get the information.
    Realize though that it could be that the JRE is already there but jar files have not been assciated with it.

  8. #8
    castiel is offline Member
    Join Date
    Aug 2009
    Posts
    26
    Rep Power
    0

    Default

    Ok, so how does one create the association?

  9. #9
    r035198x is offline Senior Member
    Join Date
    Aug 2009
    Posts
    2,388
    Rep Power
    8

    Default

    It's OS specific.

  10. #10
    castiel is offline Member
    Join Date
    Aug 2009
    Posts
    26
    Rep Power
    0

    Default

    Well one friend has XP the other has Vista,

    tanx

  11. #11
    r035198x is offline Senior Member
    Join Date
    Aug 2009
    Posts
    2,388
    Rep Power
    8

    Default

    Haven't we reached that point where you now need to do some investigations of your own?

  12. #12
    castiel is offline Member
    Join Date
    Aug 2009
    Posts
    26
    Rep Power
    0

    Default

    Sorry about that r035198x, I really appreciate the help you've been giving me and I'll look into gettin this to work on my friends computer. I'll jst head over to their house 2morrow and see if I can get it to work somehow. sorry again, I was just hoping to be able to give them some quick instructions 2 get it working. Yeh I know that asking very stupid questions without doing my own research was wrong of me and I have abused your kindness in helping me.

    Well thanks again :)

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

    Default

    Quote Originally Posted by castiel View Post
    Sorry about that r035198x, I really appreciate the help you've been giving me and I'll look into gettin this to work on my friends computer. I'll jst head over to their house 2morrow and see if I can get it to work somehow. sorry again, I was just hoping to be able to give them some quick instructions 2 get it working. Yeh I know that asking very stupid questions without doing my own research was wrong of me and I have abused your kindness in helping me.
    The best quick instructions are: "install an up-to-date JRE". If he already did so, fix the .jar file association so it can be run with a single button click.

    Otherwise it would be like asking "I want to give a program to my mom but she doesn't have a computer but she does have a vacuum cleaner, what should I do?"

    kind regards,

    Jos

  14. #14
    castiel is offline Member
    Join Date
    Aug 2009
    Posts
    26
    Rep Power
    0

Similar Threads

  1. Replies: 3
    Last Post: 09-07-2009, 08:27 AM
  2. Problem Jar executable files
    By Manfizy in forum New To Java
    Replies: 6
    Last Post: 08-13-2009, 01:15 PM
  3. executable jar with images
    By tascoa in forum Eclipse
    Replies: 3
    Last Post: 05-05-2009, 12:06 PM
  4. executable
    By smooth in forum New To Java
    Replies: 4
    Last Post: 06-14-2008, 05:12 PM
  5. Executable JAR
    By bugger in forum New To Java
    Replies: 4
    Last Post: 12-05-2007, 05:41 PM

Posting Permissions

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