B.C.S.T, SCJP, Hero
B.C.S.T, SCJP, Hero
Originally posted by Antoine Waugh:
is it possible your not in the same directory as your hello.java file?
cd c:\whatever...\bin\
javac hello.java
java hello
-twans[/QB]
Originally posted by Antoine Waugh:
out of curiosity, if your in the cmd and type:
cd C:\J2SDK1.4.2_04\BIN
then javac hello.java
does it compile?
-t1s
B.C.S.T, SCJP, Hero
Originally posted by Antoine Waugh:
this may be a stupid quetion, but is your class name the same as the files name?
unline c and other languages that create an executable.. java insists that there is ONE public class per file, and that class name (case sensitive) is the filename
so you MUST have
class Hello
{
}
for it to be called Hello.java
otherwise there will be an error..
and if in your c:\java....\bin directory, and you type 'dir' is hello.java listed?
-t1s
[ April 21, 2004: Message edited by: Antoine Waugh ]
Well don't expect me to do the dishes! This ad has been cleaned for your convenience:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
|