Do you have java.exe in your System32 folder?
I suspect this might be your problem.
See this question I recently asked.
Java Windows7 System32 folder java.exe
I suggest you remove both JDKs, then you install them both without the
option to install a public JRE (be careful about this at installation time).
Also, make sure you understand/control what is in your PATH variable.
I also have both 6 and 7 on my machine, and
since I got rid of the public JREs I am fine.