While running
sencha app build production
I am getting the following error:
Error: Registry key \'Software\\JavaSof
My short contribution, for sharing the same problem with Talend Open Studio 64 bit version.
To resolve this, remove all java.exe, javaw.exe and javaws.exe files on c:\ProgramData\Oracle\Java\javapath\
and TOS start with 64 bits version correctly !
just did this and it worked
HKLM > SOFTWARE > JavaSoft > Java Runtime Environment
just manually change current version to 1.7 .
lol ... but it worked!
As for me on win7 64bit.
Copy the java.exe javaw.exe javaws.exe in the folder C:\Program Files\Java\jre1.8.0_91\bin to the C:\Windows\System32.
and then open cmd, type java -version.
C:\Users\HEcom>java -version
java version "1.8.0_91"
Java(TM) SE Runtime Environment (build 1.8.0_91-b14)
Java HotSpot(TM) 64-Bit Server VM (build 25.91-b14, mixed mode)
Before the above make sure the Registry's CurrentVersion is 1.8
In the START menu type "regedit" to open the Registry editor
Just Install Java SE Runtime Environment JRE 7 !
Now you see "java 7" & "java 8" in "Programs and Features" in the "Control Panel"
It worked for me.
My experience:
I am using windows 8.1 and i have downgraded JAVA version from 1.8 to 1.7 and i was getting the same error.
Error: Registry key 'Software\JavaSoft\Ja has value '1.7', but '1.8' is required.
I have deleted java.exe, javaw.exe and javaws.exe from C:\Windows\System32 folder and it worked for me.
The error is explicit ...
Error: Registry key 'Software\JavaSoft\Java Runtime Environment'\CurrentVersion' has value '1.8', but '1.7' is required.
Error: could not find java.dll
Error: Could not find Java SE Runtime Environment.
... you are attempting to use the java.exe
1.7 executable while the HKEY_LOCAL_MACHINE\Software\JavaSoft\Java Runtime Environment
> CurrentVersion
registry key has the value 1.8.
The recurring theme to proposed solutions is that the error is a configuration error. The error can be solved in various different manners (e.g. reconfiguration of the users environment or removal of java executables with fingers-crossed and hope that there exists another fallback java.exe
in the users %PATH%
and that the fallback java.exe
is the correct executable).
The correct solution depends on what you're trying to achieve: "are you trying to downgrade from jdk-8 to jdk-7? Are trying to upgrade to jdk-8? ..."
notes:
- the
java.exe
executable available in the users%PATH%
is installed inC:\Windows\System32
- the installation does not update the users
%PATH%
- the
HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Runtime Environment
>CurrentVersion
string registry entry is created (among others) with the value1.7
notes:
- the users
%PATH%
is updated to includeC:\Program Files (x86)\Common Files\Oracle\Java\javapath
as the first entry- the the
HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Runtime Environment
>CurrentVersion
string registry entries value is updated to1.8
update the users %PATH%
environment variable, remove C:\Program Files (x86)\Common Files\Oracle\Java\javapath
in a new command prompt java -version
Error: Registry key 'Software\JavaSoft\Java Runtime Environment'\CurrentVersion' has value '1.8', but '1.7' is required.
Error: could not find java.dll
Error: Could not find Java SE Runtime Environment.
OP's solution https://stackoverflow.com/a/29769311/1423507 is a "fingers-crossed and hope that there exists a fallback java.exe
in the users %PATH%
and that the fallback executable is correct" approach to the error. Given the reproduction steps, removing the java.exe
, javaw.exe
and javaws.exe
executables from C:\Windows\System32
(only in my case) will result in no longer having any java.exe
present in the users %PATH%
resulting in the error 'java' is not recognized as an internal or external command, operable program or batch file.
which is not so much of a solution.
answers https://stackoverflow.com/a/35775493/1423507 and https://stackoverflow.com/a/36516620/1423507 work however you're reverting to using java.exe
1.7 (e.g. update the CurrentVersion
registry key's value to match the java.exe
version found in the users %PATH%
).
make surejava.exe
1.8 is the first found in the users %PATH%
(how you do that is irrelevant) i.e.:
%PATH%
to include C:\Program Files (x86)\Common Files\Oracle\Java\javapath
first (ensure that the executables in that directory are correct)%PATH%
to include the absolute path of your java binaries first (set PATH="C:\Program Files\Java\jre1.8.0_191\bin;%PATH%"
)%PATH%
with them (set JAVA_HOME="C:\Program Files\Java"
; set JRE_HOME=%JAVA_HOME%\jre1.8.0_191
; set PATH=%JRE_HOME%\bin;%PATH%
)