title: A simple windows Batch file to run java
body: <p>m new to java. I want to run java from windows batch file. I have a compiled class- Main.class in a directory. I want to run this with a batch file put in the same directory.
  I have a system variable set to <code>JAVA_HOME=C:\Program Files\Java\jdk1.7.0_06\bin</code></p>
  
  <p>And what if I want to compile the class with batch file first ?</p>