-1

I made a simple quiz jFrame application in netbeans. I built the project to a executable jar and it runs perfectly on my computer. When i try send it it then just says A Java Exception has occurred. So I ran it from the command prompt and it says :

Exception in the thread 'main' java.lang.UnsupportedClassVersionError: Frame: Unsupported major.minor version 52.0

I am using custom images for a background and buttons. Where should i place those? They arent in the dist folder. They were added to a scr folder when netbeans imported them.

atish shimpi
  • 4,873
  • 2
  • 32
  • 50
KMoore
  • 171
  • 1
  • 10

2 Answers2

1

Your code is compatible with Jre8 while you are running it with Jre7 which is creating problem.Change/Set JRE_HOME for Jre8 before running the program.

akash
  • 22,664
  • 11
  • 59
  • 87
  • It is not clear if the other computer used Java 1.7^^. The same error message will occure, when Java 1.6 and older is used (at least until 1.4). – Reporter Jan 08 '15 at 14:39
0

Unsupported major.minor version 52.0 Exception occure with your compilation version not match with your previous compilation version. you have to change your java version.

If you are using Eclipse go to Windows ---> Prefences then select Java and expand it then select Compiler and change the compliance level to [your JDK version] then try to compile your code with [your JDK version].

Refer, Link 1 Link 2

Community
  • 1
  • 1
atish shimpi
  • 4,873
  • 2
  • 32
  • 50