0

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

Community
  • 1
  • 1
committedandroider
  • 8,711
  • 14
  • 71
  • 126
  • How have you set `JAVA_HOME` and `PATH`? Java 7 is EOL in April 2015. I suggest you install Java 8 and then don't set any manual environment variables; instead reboot after you install. – Elliott Frisch Dec 16 '14 at 17:58
  • Yeah those environmental variables are set(values are listed above) I have to use Java 7 for Android development. Heard Android didn't support Java 8. Do you know this issue is though? Java 7 should work fine. I don't understand why java.dll cannot be found – committedandroider Dec 16 '14 at 18:02
  • @ElliottFrisch See my updated question. I set them to the correct path that Ye Win told me to do in my last question – committedandroider Dec 16 '14 at 18:10
  • I'm not certain that `Path` is correct (I think it should be `PATH`). Also, I suggest you use `%JAVA_HOME%\bin` instead. – Elliott Frisch Dec 16 '14 at 18:11
  • Thank you!!! That made all the difference. You know what's interesting though. Even though my environmental variables were set wrong, eclipse ran my java programs fine, – committedandroider Dec 16 '14 at 18:15

1 Answers1

0

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

Elliott Frisch
  • 198,278
  • 20
  • 158
  • 249