JDK configuration
Open Environment Variables
dialog.
In the System variables below, new a varible named JAVA_HOME
and the value is the path where JDK was installed.
Then edit Path
variable, insert the text below into the foremost:
%Java_Home%\bin;%Java_Home%\jre\bin;
Finally, new a variable named CLASSPATH
,the value is as follow:
.;%Java_Home%\bin;%Java_Home%\lib\dt.jar;%Java_Home%\lib\tools.jar
Done!
Go check if you are doing it right:
- Open
CMD
- type
javac
,java -version
to see if there are something output.
Addictionally, you can set the encoding of JAVA:
- add a new value named JAVA_TOOL_OPTIONS
- set its value as -Dfile.encoding=UTF-8 (or others you need)
Subscribe to JuniperPhoton's Blog
Get the latest posts delivered right to your inbox