Follow what I said above to check if you have it in the path variable,
If it's not there, you can either add it temporarily, or permanently. place this code at the top of your batch file to add it temporarily:
SET path="C:\Program Files\jre*Current Version*\bin";%path%
Or "C:\Program Files (x86)\jre1.6.0_05\bin" if you have a 64-bit operating system.
and to permanently add it:
Right click “My Computer” icon
Choose “Properties” from context menu
Click “Advanced” tab (“Advanced system settings” link in Vista)
Add the directory of JRE to the path seperating it with a semicolon (;)
Can I put a question here?