If you are looking for software to use, go to Huajun Software Park! software release
Location: front pageTutorial strategyTutorialComputer software tutorials Windows7 series...

How to install jdk and configure environment variables in Windows 7 system?

Author: Xiaoyuer Date: 2017-05-25

Sun Java SE Development Kit (JDK)
Sun Java SE Development Kit (JDK)-17.0.1 official version

JAVA program Storage size: 185 MB Time: 2022-04-06

Software introduction: JDK (Java Development Kit) is a software development kit (SDK) for the Java language. It is used to build a Java application development environment...

Download now

1. During the installation of jdk, two installation prompts will appear. The first time is to install jdk, and the second time is to install jre. It is recommended to install both in different folders within the same java folder. (They cannot both be installed in the root directory of the java folder. An error will occur if jdk and jre are installed in the same folder), as shown in the figure below:

How to install jdk and configure environment variables in Windows 7 system?

2. Install jdk, choose the directory at will, just modify the directory before the default installation directory java; install jre → change → the directory before java and the directory where jdk is installed can be the same;

Note: If there is no installation directory requirement, all default settings can be used. There is no need to make any modifications, just click Next twice.

How to install jdk and configure environment variables in Windows 7 system?

How to install jdk and configure environment variables in Windows 7 system?

3. After installing jdk, configure environment variables: Computer → Properties → Advanced System Settings → Advanced → Environment Variables;

How to install jdk and configure environment variables in Windows 7 system?

4. System variables → Create new JAVA_HOME variable.

The variable value fills in the installation directory of jdk (I am E: Javajdk1.7.0).

System variables → Find Path variable → Edit, enter %JAVA_HOME%bin;%JAVA_HOME%jrebin; at the end of the variable value.

(Pay attention to whether there is a ; sign at the end of the original Path variable value. If not, enter the ; sign first and then enter the above code)

How to install jdk and configure environment variables in Windows 7 system?

5. System variables → Create new CLASSPATH variable;

Fill in the variable value .;%JAVA_HOME%lib;%JAVA_HOME%libtools.jar (note the dot at the front);

System variables are configured.

How to install jdk and configure environment variables in Windows 7 system?

6. Check whether the configuration is successful, run cmd and enter java -version (there is a space between java and -version);

If the version information is displayed as shown in the figure, the installation and configuration are successful.

How to install jdk and configure environment variables in Windows 7 system?

The above is the process of installing jdk and configuring environment variables in the Windows 7 system environment. If you need to use jdk and set environment variables when using your computer, you can use the above method to install and set up.

Related articles