Running JAR file on Windows 10

I have made a Jar file, but I cant make it to run by double clicking.It works fine using java -jar name.jar or by making a batch file.I have already reinstalled jdk1.8.0_102, set the JAVA_HOME variable and javaw.exe in the jre folder is already the default program to run it.so how do I make it to run by double clicking?

Running JAR file on Windows

Easiest route is probably upgrading or re-installing the Java Runtime Environment (JRE). Or this: Open the Windows Explorer, from the Tools select ‘Folder Options…’ Click the File Types tab, scroll down and select JAR File type. Press the Advanced button. In the Edit File Type dialog box, select open in Actions box and click Edit… … Read more