This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes Tomcat and the fly likes Bad version number in .class file Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Bad version number in .class file" Watch "Bad version number in .class file" New topic
Author

Bad version number in .class file

Mike Landeros
Greenhorn

Joined: Dec 17, 2012
Posts: 2

I was getting the following error:

java.lang.UnsupportedClassVersionError: Bad version number in .class file

I understand it is because I was trying to run a .class or jar file that was compiled with a higher version of java than the virtual machine I was using to run it.

I downloaded and installed the latest version Java SE 7 (I use linux SLACKWARE).

I set Java_Home and Path to point to the version of java using "export"

I restarted tomcat and it recognized the new JAVA_HOME.

I ran the jsp and still got the Bad version number.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Bad version number in .class file