cmd line /w Netbeans

I have downloaded jdk1.5.0_06 /w Netbeans.

I ran the HelloWorldApp program successfully through the Netbeans IDE.

I'm trying to run the HelloWorldApp through a DOS window on WinXP Pro, but I keep getting

" 'javac' is not recognized as an internal or external command, operable program or batch file "

I added the "jdk1.5.0_06\bin" directory to both the PATH and CLASSPATH environment variables; I also added the "jdk1.5.0_06\lib\tools.jar; .; " to the CLASSPATH variable. (I looked through all the forum's postings)

I still get the same message.

Can I run java progs at the command line if I have the JDK5 /w Netbeans installed or do I have to uninstall the Netbeans IDE first, in order to run command-line Java?

I would like to be able to run Java programs both in the Netbeans IDE and through the command line.

Any help is highly appreciated

[903 byte] By [czcka] at [2007-10-3 4:10:00]
# 1
Netbeans would have no impact on running from the command line. The only thing I can think of is you have a typo or have not included the full path in you PATH. If your java directory is in a subdirectory then you need to include the parent directory.C:\Parent\jdk1.5.0_06\bin;
floundera at 2007-7-14 22:10:11 > top of Java-index,Java Essentials,New To Java...
# 2

Also, if there are spaces in the Path to JDK bin directory, you should enclose the entire path with double quotes.

"C:\Program Files\Some Install Dir\Java\You get the hint\JDK\bin"

Also, you should close the command window after you set the environment variables and then re open it so the changes take effect.

JJ

Java_Jaya at 2007-7-14 22:10:11 > top of Java-index,Java Essentials,New To Java...
# 3

Thank you for all your responses; I 've figured it out!

I did not have any spaces in my directory name path:

C:\Javastuff\Java\jdk1.5.0_08\bin

but when I put this path in double quotes in the PATH variable anyway, it worked!!

Again, thank you so much for the inspiration!

czck

czcka at 2007-7-14 22:10:11 > top of Java-index,Java Essentials,New To Java...