+ 6

How to convert .java file into .jar and .exe file?

Java is my favourite programming language. I feel a lot of fun in creating java programs. Java is portable. But while distribution it to my friends, it becomes a problem. They need Java installed in their computer to execute .java or .class file. So, please tell me how to convert my program into .jar. file or into .exe file. Thank You!!

18th Oct 2017, 6:33 AM
Shreyas Sable
Shreyas Sable - avatar
3 Answers
+ 11
You have to use an executable wrapper for converting the file (or program) extensions from .java (or .class) into .exe (or .jar). The executables in the link* below may easily help you in doing the same: * https://stackoverflow.com/a/147233/7740693
18th Oct 2017, 7:19 AM
Dev
Dev - avatar
+ 1
If you don't work with an IDE, I think you can also do that with a Linux command
18th Oct 2017, 6:22 PM
Marlene
Marlene - avatar
0
Yes, definitely you can convert jar to exe. That process is very simple and will take hardly 15 minutes to convert that. Read this Convert jar to exe file and Run exe file without JRE (https://erainnovator.com/convert-jar-exe-file/)
8th May 2020, 4:26 PM
Ashish Dhole
Ashish Dhole - avatar