The problem is that javac is not on your $PATH. run

echo $PATH

and it will show you what $PATH currently is. $PATH is where it searches for executables every time you type a command on the command line. Java directories have to be included in that list or else DOS can't find them. So you either have to add the Java directory to your $PATH, or you have to type the full pathname to javac every time you run it, i.e. c:\j2sdk_version\blah\blah\bin\javac or something similar.

Try this: http://www.cs.colostate.edu/helpdocs/JavaPaths.html#XP