Switching from Java 1.7 to Java 1.6 in Windows 7

6

I changed the JAVA_HOME and Path Variable pointing to my Java 1.6 Location from Java 1.7-> tried checking the version using java -version. It showed Java 1.7.

Next, tried deleting the Java 1.7 Installation and still version shows Java 1.7. Restarted the PC twice. Any ideas?

enter image description here enter image description here enter image description here enter image description here

AppSensei

Posted 2013-06-08T02:19:45.857

Reputation: 163

Answers

7

The easiest way to fix this is to add the Java bin dir to the beginning of your PATH instead of at the end.

Another option would be to delete Windows\System32\java.exe, so that the actual java.exe from the bin dir in your PATH is executed.

Karan

Posted 2013-06-08T02:19:45.857

Reputation: 51 857

Eh, no. Add %JAVA_HOME%\bin (or the full path i.e. C:\Java\jdk1.6.0_45\bin) to the very beginning of your PATH string. – Karan – 2013-06-08T02:45:07.110