1

I have made some GUI Java application and exported it as "Executable Jar". But Windows shows me this file as RAR archieve, and I can't execute it! How can I fix it?

0

1 Answer 1

4

From the command line, run: java -jar <jarfile>.

From Windows Explorer, right-click on the JAR file, choose "Open with..." and select your local Java installation.

Make sure you have a JRE installed. Normally Windows will recognise JAR files and do the right thing with them. The fact that they are being identified (understandably) as an archive would hint that you have no JRE.

Sign up to request clarification or add additional context in comments.

3 Comments

I don't know which Java file I should choose
@ДенисНагибин the jar file itself
@ДенисНагибин on my machine, i would "open with" the following binary: C:\Program Files\Java\jre6\bin\java.exe. hopefully yours is in a similar location and you can choose appropriately.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.