"java -version" doesn't display proper value.
I am new to java and facing a strange problem regarding java version. I have 1.4 and 1.5 both the JDKs installed on my Windows XP machine.
When I open command prompt and try to figure out what java version I have currently, it always gives me version 1.5. Even though when I set my path to “C:\j2sdk1.4.2_12\bin” and JAVA_HOME to “C:\j2sdk1.4.2_12”, this problem still persists. I wonder what I exactly need to do so that when I set my path and JAVA_HOME to 1.4 JDK it will reflect the same in “java –version” command on the command prompt.
Any help would be highly appreciated. Is there any chance that java –version is looking somewhere else than the environment variables?
Thanks in advance!:)