.jar files contain Java applications and you need Java Runtime Environment installed on your computer to be able to run Java applications.
Java Downloads for All Operating Systems - Sun Microsystems
Please try this and see if it helps.
I have a jar file which used to work in Win XP, but doesn't in Win 7. I get a message "Could not find main class: C:\users\<file path>. Program will exit."
I don't really understand jar files, but looking around the main solution seems to be the need for a 'manifest file'...which doesn't help me because a manifest file already exists and appears to define the main class.
Does anyone have any ideas?
(I did think about Win XP mode, but my Win 7 is a personal edition)
Polly
.jar files contain Java applications and you need Java Runtime Environment installed on your computer to be able to run Java applications.
Java Downloads for All Operating Systems - Sun Microsystems
Please try this and see if it helps.
Welcome to TWCF Polly, if memory serves me correct you need JDK to open jar files. You can download JDK from here Java SE Downloads - Sun Developer Network (SDN). I hope this helps. JR
have u installed java and in environment variable have u set the path(bin ) and class path (lib folder)
Thanks for all your responses
I have installed both Java Runtime Environment (JRE) and Development Kit (JDK).
I didn't understand this part, I'm afraid....and in environment variable have u set the path(bin ) and class path (lib folder)![]()
Go to Mycomputer - > right click properties - > advanced tab - >Environmental variables button
In the 2nd box you would get a 'classpath' and 'path' name
Set classpath to ur java lib folder(like D:\Program files\ java\jre1.6.2\lib) where is it installed and bin folder to path (D:\Program files\ java\jre1.6.2\bin)
This allow u to use from command prompt and solves most of the issues.![]()
Well, I added path (bin) and classpath (lib) for both 32 bit (Program Files (x86)) and 64 bit (Program Files) applications.
Sad to say, it has not made any difference and I still get the same unhelpful message.
Polly
normally jar files are of two types executable jars and non executable jars non executable jars will need to be run from a program so it shud have a main class in it. But i presume this is a executable one but use a jaav jdk to make it executable u can try unrar the jar file or converting the existing jar file to executable one.
I am not a pro in java but know something
Try runnin this from the command prompt
java -jar name_of_jar_file.jar
Yay!!!
Thank you!!!
It has worked. :-)))))))
Hello Friends........
If you install the Java Runtime Environment or if you already have the Java Runtime Environment then you have follow this steps to open the Jar files in Windows:-
1) Open the Windows Explorer and click on the menu bar of Tools and the select the Folder Options.
2) Now click on the sub-tab option File Types.
3) Now select the Jar option from the list.
4) Now click on Advanced button.
5) Now select the Action button and then click on Edit button.
6) Now click the Browse button and select the Java Interpreterjavaw.exe.
Thanks
Bookmarks