Solution to the error reported by the java -version command: First open the [Windows\System32] and [Windows\SysWOW64] folders in the C drive; then find [java.exe], [javaw.exe], [javaws .exe] file can be deleted.
Solution to the error reported by the java -version command:
Problem description:
Install jdk After entering "java -version" in the dos interface and pressing Enter, the following error is reported:
Error opening registry key'software\Javasoft\Java Runtime Environment' Error: could not find java.dll Error: could not find Java 2 Runtime Environment'
Solution:
Change the Windows\System32 and Windows\SysWOW64 folders in the C drive Just delete thejava.exe
,javaw.exe
,javaws.exe
files.
PS: Delete the java.exe and javaw.exe files under Windows\System32 in the win7 environment, and the problem will be solved.
Related free learning recommendations:java basic tutorial
The above is the detailed content of What to do if the java -version command reports an error. For more information, please follow other related articles on the PHP Chinese website!