Hi, I have a MyFirstApp.java program, I can run it by the command line with java MyFirstApp, but how would someone run it from their desktop like you would with an exec. file? Please. Any help greatly appreciated. Thank you. :D
Printable View
Hi, I have a MyFirstApp.java program, I can run it by the command line with java MyFirstApp, but how would someone run it from their desktop like you would with an exec. file? Please. Any help greatly appreciated. Thank you. :D
Hi silverglade,
The main feature of Java is that it can be run on different platform. You need to build a .jar file. If you are using an IDE there should be a function that does it. Or you can encapsulate your .class files in .jar files.
To actually build an .exe you can use a simple applications called launch4j.
Hope it helps.
Hello.
Look into creating a jar file rather than an exe. As long as they have Java installed (and most OS installations do), they should be able to run the Jar file by double clicking it.
Thank you very much Flynn and Fubarable. That helps a lot! Then I will be able to share my newbie apps with my friend over the net which will be hilarious . I will just send them to his email, and he can see my newbie java uberness. LOL. THANK YOU!!!
In case if you are interested : How To Create A JAR File
Hope that helps,
Goldest