Monday, 24 December 2018

windows - Why is java -version returning a different version to the one defined in JAVA_HOME?


My JAVA_HOME is set to C:\bea\jdk150_10\bin (Java 1.5). However, when I run java -version I get the following:


java version "1.6.0_22"
Java(TM) SE Runtime Environment (build 1.6.0_22-b04)
Java HotSpot(TM) Client VM (build 17.1-b03, mixed mode, sharing)

How can I use the 1.5 version?



Answer



As Mikel has mentioned, In your machine java is taken from C:\Windows\System32\java.exe.


Change the Path in the System Environment variables as mentioned by John T.


And modify it have the C:\bea\jdk150_10\bin before %SystemRoot%\system32 in the path.


No comments:

Post a Comment

Where does Skype save my contact's avatars in Linux?

I'm using Skype on Linux. Where can I find images cached by skype of my contact's avatars? Answer I wanted to get those Skype avat...