Search code examples
javaregistryruntimeenvironmentregedit

Why am I getting cannot find Java SE Runtime Environment again?


I thought i fixed this issue last night.......... Last night I had this issue, Why am I still getting a cannot find Java SE Runtime Environment?, reinstalled the jdk and everything was working fine. This is the output I got last night when I ran java -version(correct output) enter image description here

However when I turned on my pc today, heres what I got, enter image description here

This is extremely frustrating..... From that last thread, first I made sure that C:\Program Files\Java\jdk1.7.0_71\jre\bin contained the java.dll library file which it did after i did a search.(this was why it was previously broken.) enter image description here Afterwards, I tried Ye Win said in the answers to my last question which was to "Delete all previous versions of Java" and "Clean up your registry(delete your java key)" by going to https://java.com/en/download/help/manual_regedit.xml

I checked over my path variables which were

JAVA_HOME - C:\Program Files\Java\jdk1.7.0_71

Path - C:\Program Files\Java\jdk1.7.0_71\bin

At this point, I really don't what to do ........ I don't know if this helps but my pc runs 64 bit windows operating system. has a x64-based processor. I would go out and buy a new pc but this is a new pc...

enter image description here enter image description here


Solution

  • Your environment variable Path is incorrect. It's supposed to be PATH, and I would set it by adding

    %JAVA_HOME%\bin
    

    instead of expanding the JAVA_HOME variable manually. Finally, eclipse stores local JRE installations under "Window > Preferences > Java > Installed JREs"

    Installed JREs