Java Learning 01:win7 Environment installation JDK

Source: Internet
Author: User

Start learning Java recently, starting with the first step. Installing the JDK in Win7 is simple, so don't spray it.

1. Download the JDK and perform the installation.

Visit the website www.java.com and select the Win7 version of the JDK download. Double-click Install after download (slow, patient wait).

Note that the default directory for the installation is c:\ProgramFiles\java\ ... and the default pathname with spaces is not recommended. Delete the Program Files section.

2. Setting Environment variables

An environment variable is a list of directories that the operating system searches for a local executable file, and if the input Java command under DOS is prompted to be "' xxx ' is not an internal or external command ..." then it is because the environment variable is not set.

Right-click the environment variable, advanced system settings, properties, computer, and enter the environment variable Settings window.

    • Create a new "java_home" variable in the system variable with a value of the installation directory in step 1, such as "C:\java\jdk1.8.0_60" .
    • Create a new "classpath" variable in the system variable with the variable value: ".; %java_home%\lib;%java_home\lib\tools.jar ".
    • Locate the system variable "path" and in the edit the variable add the following: "%java_home%\bin;%java_home%\jre\bin". (each variable value is separated by a semicolon ";") Separated).

3. Testing

Enter "Java-version" in cmd if prompted, it indicates that the installation configuration was successful.

  

  

  

  

Java Learning 01:win7 Environment installation JDK

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.