By the way, I am installed JBOSS 4.0.5.GA and I used the java -jar jems-installer-1.2.0.CR1.jar to install it.
You need to set JAVA_HOME to the directory where you installed the JDK (not the JRE!). For example:
Or you can set it in the My Computer properties dialog.
By the way, safe yourself some grief and move JBoss and the JDK out of Program Files. Spaces in directory names gives some Java code fits.
By the way, you can leave the JRE in Program Files. You will rarely use it anyway.
Thanks again Peter. I got it working. You rule!!!!