How to fix java.lang.UnsupportedClassVersionError: Unsupported major.minor version

Ads

 
 

Share on Google+Share on Google+

Java Coder
How to fix java.lang.UnsupportedClassVersionError: Unsupported major.minor version
1 Answer(s)      4 months and 11 days ago
Posted in : Java Beginners

Hi,

I am not able to run my Java program its giving following error:

Unsupported major.minor version 51.0

How to fix java.lang.UnsupportedClassVersionError: Unsupported major.minor version?

thanks

Ads
View Answers

May 13, 2017 at 8:05 PM


Hi,

Error comes when

a) You have compiled your java file in new version of Java and b) Trying to run it in lower version of Java

To solve this you should compile your Java file with the same version of JDK.

For example:

javac -target 1.5 HelloWorld.java

thanks


Ads









Related Tutorials/Questions & Answers:
How to fix java.lang.UnsupportedClassVersionError: Unsupported major.minor version
error: Unsupported major.minor version 51.0 How to fix java.lang.UnsupportedClassVersionError: Unsupported major.minor version? thanks   Hi, Error...How to fix java.lang.UnsupportedClassVersionError: Unsupported major.minor
please how fix this error?
How to Fix Error   for this following code : $var1 = $_POST["name"]; $var2 = $_POST["id"]; $st = 'INSERT INTO USERNAME(id,name) VALUES(:var1,:var2)'; $query = ociparse($con,$st); OCIBindByName($st ,':va1',$var1
Advertisements
Version of com.intersult>jpa-fix dependency
List of Version of com.intersult>jpa-fix dependency
exception in thread main java.lang.unsupportedclassversionerror unsupported major.minor version 50.0 - Java Beginners
java.lang.unsupportedclassversionerror unsupported major.minor version 50.0 class xxx { public static void... java.lang.unsupportedclassversionerror unsupported major.minor version 50.0 ... major.minor version 50.0  Below class is compling but runtime i am
exception in thread main java.lang.unsupportedclassversionerror unsupported major.minor version 50.0 - Java Beginners
java.lang.unsupportedclassversionerror unsupported major.minor version 50.0...exception in thread main java.lang.unsupportedclassversionerror unsupported major.minor version 50.0  I am getting the below error when the class now
How to fix HAX Kernel Module Is Not Installed error?
How to fix HAX Kernel Module Is Not Installed error?  Hi, How to fix HAX Kernel Module Is Not Installed error? Android studio gives following error: emulator: ERROR: x86 emulation currently requires hardware acceleration
javax.servlet.ServletException: Database/DatabaseBean (Unsupported major.minor version 50.0) - JSP-Servlet
javax.servlet.ServletException: Database/DatabaseBean (Unsupported major.minor version 50.0... java.lang.UnsupportedClassVersionError: Database/DatabaseBean (Unsupported major.minor version 50.0...javax.servlet.ServletException: Database/DatabaseBean (Unsupported major.minor
one error but i dont know how to fix it o_O!!!
one error but i dont know how to fix it o_O!!!  where is the mistake here ?? import java.utill.Scanner; public class Time { public static void main (String [] args) { Scanner keyboard = new Scanner (System.in
infix to post fix convertion
infix to post fix convertion  a+(bc-(d/e^f))*h
please fix the error
please fix the error  org.apache.jasper.JasperException: Unable to compile class for JSP: An error occurred at line: 14 in the jsp file: /doctor.jsp Invalid character constant 11: Connection con
need to fix errors please help
need to fix errors please help  it does have 2 errors what should i fix? import java.io.*; class InputName static InputStreamReader reader = new InputStreamReader(system.in); static BufferedReader input = new BufferedReader
Maven Dependency jpa-fix >> 1.1
You should include the dependency code given in this page to add Maven Dependency of com.intersult >> jpa-fix version1.1 in your project
Apache Struts 2.3.15.2 launched to fix vulnerable Feature
Apache Struts 2.3.15.2 launched to fix vulnerable Feature In a recent... version of Apache Struts development framework to overcome two major problems...-based Web applications and the recently launched version of Apache Struts called
Fix Scrollbar position in a checkboxList after postback
Fix Scrollbar position in a checkboxList after postback  Hi, I have a CheckBoxList in which have lot of items and i set AutoPostBack="True".I am using Scrollbar on this list.Now when I am checking any item then after postback
Please help me fix this code - MobileApplications
Please help me fix this code   Please help me in this area of code. i used three record store for each form I want expenses button to display all the expenses for the selected trip. i want to use image
Maven Dependency diff_2.11 >> 1.2.0-get-simple-name-fix
You should include the dependency code given in this page to add Maven Dependency of ai.x >> diff_2.11 version1.2.0-get-simple-name-fix in your project
How to see ubuntu version on server?
How to see ubuntu version on server?  Hi, Its easy to see the version of Ubuntu on the Ubuntu Desktop operating system. But I have a server on which I have ssh access. How to see ubuntu version on that server? Thanks  
How to check Hadoop version in Ubuntu?
How to check Hadoop version in Ubuntu?  Hi, I am trying various commands like hadoop --version to get the hadoop version in Ubunut. I am connected to Hadoop cluster through ssh terminal. How to check Hadoop version in Ubuntu
How to Find PHP version and configuration?
How to Find PHP version and configuration?  Find PHP version and configuration   If you want to find the version of PHP, you can just run...: http://www.phpzag.com/find-php-version-and-configuration
where do I find the fix for tree view catalog not expanding and collapsing correctly for roseindia shopping cart 1.1
where do I find the fix for tree view catalog not expanding and collapsing correctly for roseindia shopping cart 1.1  where do I find the fix for tree view catalog not expanding and collapsing correctly for roseindia shopping
How to uninstall old version of Android Studio?
How to uninstall old version of Android Studio?  Hi, I have old version of Android Studio. How to uninstall old version of Android Studio? Thanks   Check following video: Thanks
How to use place hoder in IE(version : 8)
How to use place hoder in IE(version : 8)  how to use placeholder for input field(type=text) and password field (type= password) in IE
how to print the server time
how to print the server time  how to print the server time in jsp and update time in fix interval
how to create a jave version excel in jsp
how to create a jave version excel in jsp  I would like to create a java version excel in JSP. so the excel like document can be published in the internet. the user will be able to enter the information and click the save button
Can someone review my script for an apparent parsing error? -it isn't quite finished yet, but I want to fix error first
Can someone review my script for an apparent parsing error? -it isn't quite finished yet, but I want to fix error first   import java.util.Scanner...;Does anyone know how to get it to be in java format instead of stickint
How to find version of Java installed on my computer? - Java Beginners
How to find version of Java installed on my computer?  How to get version of Java?  What is Java?If is say it in simple words than Java... made in JDK 1.0 since it has been introduced.So every new version of Java comes
Fix table's column's name row(1st row of the table) so that it does not move up when the table is scrolled up to view more rows below
Fix table's column's name row(1st row of the table) so that it does not move up when the table is scrolled up to view more rows below  HI, I have a table in which the data is fetched from database. The table has 20 columns
How to rectify "Bad version number in .class file" exception in Eclipse
How to rectify "Bad version number in .class file" exception in Eclipse  HTTP Status 500 - type Exception report message description... this request. exception javax.servlet.ServletException: Bad version number in .class
How to set NSZombieEnabled iPhone
How to set NSZombieEnabled iPhone  Hi, In my application I have to find and fix the object release issue. How to set NSZombieEnabled iPhone to find the bugs? Thanks   Hi, Please see the thread NSZombieEnabled iPhone
Limit the Class Object Creation
Limit the Class Object Creation In this section you will learn about how a class object creation can be a restricted to a fix number of times. In this tutorial I am giving a sample code which will demonstrate you about how
I want to know how can I create sessionfactory in hibernate 4 (latest version)
I want to know how can I create sessionfactory in hibernate 4 (latest version)  Hello, I want to create sessionfactory in hibernate 4 (latest version) and I would like your help for it..An example would be of great help

Ads

 
Advertisement null

Ads