jdk1.5.0_07的环境变量设置

来源:百度知道 编辑:UC知道 时间:2024/05/23 15:56:15
我的JDK 安装在 C:\JDK里面 变量应该怎么设置呢

如果 JDK在"C:\JDK\jdk1.5.0"

打开我的电脑-点击右键属性,高级-环境变量-系统变量-新建-
变量名:JAVA_JAVA_HOME

变量值:C:\JDK\jdk1.5.0

然后找到"Path"点击编辑,在最前面加上C:\JDK\jdk1.5.0\bin;然后点确定
注意一定要在加";"分号!!!!

测试一下:在命令提示符下输入java,如果出现下列就ok了!!!
Microsoft Windows XP [版本 5.1.2600]
(C) 版权所有 1985-2001 Microsoft Corp.

C:\Documents and Settings\ljk>java
Usage: java [-options] class [args...]
(to execute a class)
or java [-options] -jar jarfile [args...]
(to execute a jar file)

where options include:
-client to select the "client" VM
-server to select the "server" VM
-hotspot is a synonym for the "client" VM [deprecated]
The default VM is client.

-cp <class search path of directories and zip/jar files>
-cla