Question:
Java... can anyone help me with JAVA_HOME?
Mariam
2006-09-23 01:49:40 UTC
I have C:\Program Files\Java\jdk1.5.0_07 installed and added: the JAVA_HOME environment variable with classpath of C:\Program Files\Java\jdk1.5.0_07; C:\Program Files\Java\jdk1.5.0_07\bin but i type javac -help from a cmd prompt it says 'javac' not recognised.

When i then try to run the startup script for tomcat it says java isn't set up properly, should point to JDK not JRE (but it is pointing to the jdk).

Any help would be greatly appreciated!
x
Four answers:
Nagesh K
2006-09-23 09:00:22 UTC
when try to execute any exe file it first checks the path environmental variable to find the location of the file, so after setting the JAVA_HOME try appending this path to your path like this



SET PATH=%PATH%;JAVA_HOME



This will solve your issue.



in order to run the .java file set the classpath environmental variable like this



SET CLASSPATH=%CLASSPATH%;YOUR_JAVA_DIRECTORY_WHERE YOU_STORE_.JAVA FILE
bose
2006-09-23 03:38:26 UTC
plz check whether ur doin the programes in bin directory or not becoz ur calss path is set to bin directory

cd jdk1.4

cd bin

javac filename.java

java fileaname
catzpaw
2006-09-23 03:34:32 UTC
Uninstall your current Java and try this link to download.



http://www.filehippo.com/download_java_runtime/ or http://www.java.com/en/download/index.jsp
Siu02rk
2006-09-23 02:17:07 UTC
You may need to look into this at sun's website


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...