1. 下载JDK 安装包。
acle/technetwork/java/javase/downloads/jdk7-downloads-1880260.html
文件名: jdk-7u17-windows-x64
2. 双击安装 JDK.
JDK 安装路径默认。并且记下来。  C:\Program Files\java\jdk1.7.0_09
点下一步 装 JRE , 路径默认。
( C:\Program Files\java\jre7)
3. 设置环境变量 (共有3个环境变量:JAVA_HOME, classpath, path )
右键“计算机” —> 属性 —> “高级系统设置” —> “高级”选项卡 —> “环境变量”-->  系统环境变量
·······························································································
点“新建”, 变量名:JAVA_HOME 
变量值: C:\Program Files\java\jdk1.7.0_09
和JDK的安装路径是一样的,刚才记下来,是用在这里的。输入后,确定。
·····························································································
再点“新建”, 变量名:
classpath
变量值:   
.;%JAVA_HOME%\lib\dt.jar;%JAVA_HOME\lib\tools.jar;
注意!!!前面的点分号.,  千万不能忘记了!!
····························································································
第三个变量不用新建,已经有了,变量名: path    按“编辑”
可发现里面本来有内容,不要删除这些内容!!而是直接在已有内容的--> 前面,黏贴上如下代码:
安装jdk环境变量如何配置.
;%JAVA_HOME%\bin;
同样不要忘记前面的点分号.,  还有最后的分号;
·························································································
4. 检验
开始-> 最下的搜索框里 输入 cmd 回车
输入 java , 回车
如出现类似如何使用java之类的大段文字,则成功设置了。

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。