简体   繁体   English

无法运行.jar文件在学校电脑上

[英]Can't run .jar file on school computer

So I made a java program at home, but I want to run it on a school computer.于是在家里做了一个java程序,但是想在学校的电脑上运行。 I've exported it to a.jar file.我已将其导出到 a.jar 文件。 I can't download a JRE or JDK in the Program Files folder, as that needs admin perms.我无法在 Program Files 文件夹中下载 JRE 或 JDK,因为这需要管理员权限。 I've tried getting a folder with java in it and running it that way, but it doesn't work.我尝试获取一个包含 java 的文件夹并以这种方式运行,但它不起作用。 And no, I can't use cmd, because that gets blocked off the computer.不,我不能使用 cmd,因为它会被计算机阻止。 When I try to run the.jar file, it shows up with a command prompt type window with like 2 lines of text.当我尝试运行 .jar 文件时,它会显示一个命令提示符类型 window 和两行文本。 Same thing happens for another.jar file that I know 100% works, so it isn't an error.另一个我知道 100% 有效的 jar 文件也会发生同样的事情,所以这不是错误。 Is there some way I haven't tried that might work?有没有我没有尝试过的方法可能有效?

You need to install JRE or JDK.您需要安装 JRE 或 JDK。 No other way.没有其他办法了。 Java needs JVM to be run Java 需要 JVM 才能运行

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM