如何打开/运行 .jar 文件(双击不起作用)? [英] How to open/run .jar file (double-click not working)?
问题描述
我无法打开或运行我的 .jar 文件.
I can't open or run my .jar file.
我刚刚安装了java,但我尝试先用其他程序打开.jar,所以双击默认为其他内容,我无法将其更改回来.
I just installed java, but I tried to open the .jar with other programs first, so the double-click defaults to something else and I can't change it back.
java -jar myfile.jar`
以上命令返回:
'java' 不是内部或外部命令,也不是可运行的程序或批处理文件.
'java' is not recognized as an internal or external command, operable program or batch file.
有没有办法让我仍然可以打开/运行它?
Is there a way I can still open/run this?
e:操作系统是 Windows 8.
e: OS is Windows 8.
另外,我下载了 .jar 文件;不是自己创建的(如果相关的话)不确定它是否包含可执行文件(但我认为它包含).
Also, I downloaded the .jar file; didn't create it myself (if that's relevant) Not sure if it contains an executable (but I think it does).
推荐答案
您可以使用命令提示符:
you can use the command prompt:
javaw.exe -jar yourfile.jar
希望它对你有用.
这篇关于如何打开/运行 .jar 文件(双击不起作用)?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!