Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

java eroor

Status
Not open for further replies.

bhavin12300

Programmer
Oct 12, 2006
24
IN
i am getting following error i try to execute the class file


it gets compile properly but ut gets following error when i try to run the program
here are the rror


Exception in thread "main" java.lang.UnsupportedClassVersionError: Bad version n
umber in .class file
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.access$100(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)



so can anyone tell me what to do with this

i willl be thank full to you
thansk in adnvace

 
UnsupportedClassVersionError indicates, that you try to execute a new class (i.e.: 1.6) with an old jre (i.e.: 1.5).

Different subversions (1.4.2 to 1.4.1) don't count here.

It's a typical occurence, if you OS has a preinstalled JRE to run java-programs, and you later install the JDK.

Code:
which java
tells you on a linux system, which java is used (i.e.: /usr/local/bin/java).

don't visit my homepage:
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top