JDK installation and configuration environment variables Win10

JDK installation and configuration environment variables Win10

JDK download and installation (simple instructions)

  1. Baidu search JDK1.8

  2. download

  3. Double click to install JDK

Configure environment variables

  1. My Computer –> Right Click –> Properties

  2. Environment Variables --> Add a variable named JAVA_HOME and the path is the JDK path
    insert image description here

  3. Configure the path address
    insert image description here

Verify that the installation was successful

  1. Open the cmd console

  2. Enter java -version
    insert image description hereif it appears:
    Error: Registry key 'Software\JavaSoft\Java Runtime Environment'\CurrentVersion'
    has value '1.8', but '1.7' is required.

    It means that jdk7 may have been installed before, and there is no clean
    solution for some files :
    1. Search java in the C:\Windows\System32 directory, and three exes come out: java, javaw, javaws. Delete all three exes.
    Check to see if the environment variable is referenced correctly.

    If it shows:
    java version “1.8.0_231”
    Java™ SE Runtime Environment (build 1.8.0_231-b11)
    Java HotSpot™ 64-Bit Server VM (build 25.231-b11, mixed mode)
    Congratulations! Successful installation

Guess you like

Origin blog.csdn.net/weixin_41317840/article/details/111657847