Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

How can I configure .jar files run on double-click in Windows 7?

share|improve this question
add comment

4 Answers 4

up vote 0 down vote accepted

Open regedit.exe search for : HKEY_CLASSES_ROOT\jarfile\shell\open\command

Probably, you have in the value:"C:\Program Files\Java\jre7\bin\javaw.exe" -jar "%1" %* change it to "C:\Program Files\Java\jre7\bin\java.exe" -jar "%1" %*

(make sure that the path points to your actual java.exe, for it depends on the java version you have installed)

Good luck. It worked for me. ;-)

share|improve this answer
    
Actually it's not necessary to use javaw. java.exe is ok for me. But the whole command was missing. –  user626528 Jun 7 '13 at 6:05
add comment

Instructions for configuring the file assocations you'll need can be found here:

  jar : Java Glossary - Making Jar Files Double Clickable
  http://mindprod.com/jgloss/jar.html#ASSOCIATION

share|improve this answer
    
Buy a tool for this? You must be kidding. –  user626528 Jun 7 '13 at 6:06
add comment

What I did was to make a shortcut to the jar file and edit it to open "java -jar path/to/file.jar". It's the only workaround I have come up with.

share|improve this answer
add comment

In Windows 7 64 you might also find the 32bit registry key:

HKEY_CLASSES_ROOT\jar_auto_file\shell\open\command

This key might be set to 32bit values ( "C:\Program Files\Java\jre7\bin\java.exe" -jar "%1" or alike) creating conflict with 64 bit version thus the issue, so adjust it to this value:

"C:\Program Files\Java\jre7\bin\javaw.exe" -jar "%1" %*

You should be good to go with double-clicking executable jar files without conflict, now.

Cheers

Bob Qwack

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.