Monday, November 17, 2008

Problem with the Netbeans 6.1 installer ????

I was trying to intall netbeans-6.1-ml-windows.exe on vista and faced some inital problems. After setting them correct there was another blocker in the store for me... 

I was installing that from the command line...
D:\softwares\myeclipse>netbeans-6.1-ml-windows.exe --javahome C:\Java\jdk1.5.0_06
and it showed me "Unsupported Java VM version".

So i need to update my Java. 
My concerns in updatng the java are:
1. So when i update will it intall java 6 on my machine???
2. How to stick to java 5.x and get the latest in Tiger???
 

java -version ????

I was trying to install netbeans on vista and the installer says  

JDK 6 or JDK 5 is required for installing the NetBeans IDE. Make sure that the JDK is properly installed and run installer again.
You can specify valid JDK location using --javahome installer argument. 

so when i try to check my intalled java version number it says

C:\Users\Naresh>java -version
Registry key 'Software\JavaSoft\Java Runtime Environment\CurrentVersion'
has value '1.5', but '1.6' is required.
Error: could not find java.dll
Error: could not find Java SE Runtime Environment.

To solve this i tried everything  changing, adding and deleting the registry entries whatever i felt would solve the issue. After digging into the issue somewhere i found a pointer to look into the java.exe in the C:\Windows\System32 folder.

Here I found that the java.exe is from java 6.0, i thought of replacing this with java.exe of 5.0 and suddenly it all worked :-) . So there is nothing that we could actually change in the registry

and finally 

C:\Users\Naresh>java -version
java version "1.5.0_06"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_06-b05)
Java HotSpot(TM) Client VM (build 1.5.0_06-b05, mixed mode, sharing)