是什么导致“无法访问jar文件”错误? [英] What causes "Unable to access jar file" error?
本文介绍了是什么导致“无法访问jar文件”错误?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想在不使用IDE的情况下执行我的程序。
我创建了一个jar文件和一个exectuable jar文件。当
我双击exe jar文件时,没有任何反应,当我尝试在cmd中使用该命令时它给了我:
I want to execute my program without using an IDE. I've created a jar file and an exectuable jar file. When I double click the exe jar file, nothing happens, and when I try to use the command in cmd it gives me this:
Error: Unable to access jarfile <path>
我使用命令: java -jar Calculator.jar
我是如何创建jar的:
How I created the jar:
- 右键单击项目文件夹(计算器)
- 选择
- 单击Java文件夹并选择Exectuable Jar文件,然后选择下一个
- 启动配置:主要 - 计算器
- 创建导出目的地
- 点击完成并获利!好吧,不是真的。
- Right click on project folder (Calculator)
- Select
- Click on Java Folder and select "Exectuable Jar File", then select next
- Launch Configuration: Main - Calculator
- Create Export Destination
- Hit "Finish" and profit! Well, not really.
推荐答案
已修复
我只是把它放在一个不同的文件夹里就可以了。
I just placed it in a different folder and it worked.
这篇关于是什么导致“无法访问jar文件”错误?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文