无法在 Windows 7 64 位中正确设置 java 路径
我已经在计算机中安装了 java 1.6,并且还使用高级变量设置设置了路径。
在命令提示符下,当我尝试执行 java 时,出现此错误:
Error: could not open `C:\Program Files\Java\jre7\lib\amd64\jvm.cfg'
但是当我从命令提示符执行此命令时: javac -version 它显示我设置了正确的版本。
javac 1.6.0_27.
有人请帮我解决这个错误。
I have installed java 1.6 in my computer and I have also set the path, using the advanced variable settings.
At a command prompt when I tried to execute java I got this error:
Error: could not open `C:\Program Files\Java\jre7\lib\amd64\jvm.cfg'
But when I executed this command from a command prompt: javac -version it was showing that I had the proper version set.
javac 1.6.0_27.
Someone please help me to solve this error.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
Windows 7
Windows 7
当我从 Windows 7 笔记本电脑中删除 java 7 然后尝试启动 Eclipse 时,我遇到了同样的错误。您也必须在某个时候安装过 java 7,否则您不会收到此错误。
删除文件夹还不够。我必须使用控制面板卸载功能将其删除,而对于旧版本的 java,您只需删除安装 java 的文件夹。无论如何,在我卸载它后它又可以工作了。
I got this same error when I removed java 7 from my windows 7 laptop and then tried to startup eclipse. You must have java 7 installed at some time as well or you wouldn't have gotten this error.
Deleting the folders wasn't enough. I had to remove it using the control panels uninstall feature, whereas with older versions of java you just deleted the folder where java was installed. In any event, it worked again after I uninstalled it.