How to set path for Jre 6 when jre 7 installed?

前端 未结 12 1040
深忆病人
深忆病人 2021-01-18 00:19

I am programming through java 1.6 u_17, but i have JRE version 6 and JRE version 7 installed, so how to run my compiled program from JDK 1.6 to run through the JRE 6 only?<

12条回答
  •  忘掉有多难
    2021-01-18 00:47

    java.exe is also available in C:\windows\system32 and in your case its version might be 1.7..

    Since your path has C:\windows\system32 first. no matter how to set rest of the path, sonar always will load jre7. (refer to conf\wrapper.conf in Sonar directory, by default it has wrapper.java.command=java)

    To fix this, change following property of the "wrapper.conf" file wrapper.java.command=C:\Program Files\Java\jdk1.6.0_XX\bin\java

    this will fix the issue irrespective of the path variables.

提交回复
热议问题