After downloading and installing JDK from the disk, go to C: directory (or which ever drive you installed too), and find the folder just installed.
It will have a name like j2sdk1.4.2_06. Uppercase or lowercase is not important. But if your folder has a slightly different name, write it down exactly. I'll call it name in what follows.
Under the Start menu, select Control Panel, from this pick System. In the System properties window, click the Advanced tab, then the Environment Variables button (near the bottom of the window).
You are going to change the System Variables. In this window click PATH and then the Edit button. (If PATH does not exist, use the New button to make one). At the end of the string you are editing, add
;C:\j2sdk1.4.2_06\bin
(That's a semicolon, the letter C, a colon, a backslash, the name you wrote down earlier, a backslash, and the word bin.) Click OK. Then reboot.
In the Command Prompt window, type javac. If it says not found, you have a problem. If it complains about a missing file, things are ok.