I win7 x64 Ultimate Edition, installed JDK7 and jdk8 at the same time, after uninstalling jdk8, the CMD command line input: Java – version, originally thought to display java version 1.7, the result of error: has value ‘1.7’, but ‘1.8’ is required
I look at Java_ Home, the environment variable, is found to be OK, pointing to C:// Java/jdk1.7.0
resolvent:
After JDK7 is installed, jdk8 is installed, because when JDK1.8 is installed, java.exe, javaw.exe and javaws.exe are automatically copied to the directory C: (Windows) system32, because the priority of this directory in the windows environment variable is higher than Java_ The priority of the environment variable set by home.
After understanding this, you will know the cause of the error. Although JDK1.8 has been uninstalled, the three executable files of java.exe, javaw.exe and javaws.exe in the directory of C: (Windows) system32 are still JDK1.8, so the Java version of jdk1.7 is_ Copy the three corresponding executable files under home/bin to the directory of C: Windows/system32. At this time, enter Java – version on the command line of CMD, and everything is normal.
My situation is just the opposite of his, so I replace several files of jdk8 and overlay them in the directory of C: (Windows) system32.
According to the above modification, enter Java – version in CMD to display version 1.8
Read More:
- Registry key Error: Java version has value ‘1.8‘, but ‘1.7‘ is required
- Solve the problem that stdole32.tlb is missing when win7 Microsoft Office 2007 Pro Plus excel is opened
- How to solve the problem of requirements check failed for JDK 8 when Cordova 9.0 is built
- How to solve the problem of “version 11 or greater is required” in eclipse 2020
- The problem of MAC switching JDK version and RN Android JDK version leads to compilation failure. Solve it
- An error is reported when installing the package directly in pycharm, but it can be installed through the terminal. Error non zero exit code (2)
- Could NOT find CUDNN: Found unsuitable version “..“, but required is at least “6“
- When nodejs is installed: the error code is 2503
- Version 1.8.0_201 of the JVM is not suitable for this product. Version: 11 or greater is required.
- Installing R’s “mvtnorm” package in Windows system: solving the problem of the R package “mvtnorm” is not installed
- After Oracle 11g is installed, SQL_ Plus.exe The problem of Chinese garbled in command window
- CONDA HTTP error is prompted when Anaconda prompt is installed and updated
- After openstack neutron is installed, the Linux bridge starts and the error is resolved
- java.lang.IllegalArgumentException: Index for header ‘XXX‘ is 1 but CSVRecord only has 1 value
- After node.js is installed, use the instruction node version in vscode to show that it is not an external or internal instruction. The solution is as follows:
- Pikachu vulnerability is installed in the shooting range, and an error is reported when connecting to the MySQL database
- After matlab2018a is successfully installed, a licensing error appears when it is opened: – 8523
- Importerror: DLL load failed while importing win32gui: 1 is not a valid Win32 Application.
- “XXXXXX is a” namespace “, but here it is used as a” type “
- Error code is 2502 / 2503 when installing MSI format installation package under win10 or win8