title: Invoking jdk 7 compiled class from jdk6
body: <p>I hava  class compiled using jdk7 and I am trying to invoke using JDK6 and the jars in classpath are compiled using jdk 6</p>
  
  <pre><code>jdk6/bin/java com.test.myclass -classpath abc.jar xyz.jar pqr.jar MNO.jar
  </code></pre>
  
  <p>my class <code>com.test.myclass</code> is present in <code>MNO.jar</code> and  <code>abc.jar xyz.jar pqr.jar</code> are compiled with jdk6</p>
  
  <p>with jdk7 it works</p>
  
  <pre><code>jdk7/bin/java com.test.myclass -classpath abc.jar xyz.jar pqr.jar MNO.jar
  </code></pre>
  
  <p>This also fails.Any input to solve this problem.?</p>
  
  <pre><code>Exception in thread "Main Thread" java.lang.UnsupportedClassVersionError: com/test/MyClass: unsupported classversion 51.0
      at java.lang.ClassLoader.defineClass1(Native Method)
      at java.lang.ClassLoader.defineClassCond(ClassLoader.java:631)
      at java.lang.ClassLoader.defineClass(ClassLoader.java:615)
      at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
      at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
      at java.net.URLClassLoader.access$000(URLClassLoader.java:58)
      at java.net.URLClassLoader$1.run(URLClassLoader.java:197)
      at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
      at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
  Could not find the main class: com.test.MyClass.  Program will exit.
  256
  </code></pre>
  
  <p>Thanks</p>