| Author |
Exception
|
Tontang Bei
Ranch Hand
Joined: Oct 21, 2006
Posts: 130
|
|
why is the code below giving me an exception?
|
 |
Keith Lynn
Ranch Hand
Joined: Feb 07, 2005
Posts: 2341
|
|
|
What is productPrice[4][4]?
|
 |
Tontang Bei
Ranch Hand
Joined: Oct 21, 2006
Posts: 130
|
|
Okay even productPrice[1] is giving the exception. And shouldnt it be an ArrayoutofBOuds exception if this was the problem? This exception is: Exception in thread "main" java.lang.UnsupportedClassVersionError: Bad version number in .class f e 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)
|
 |
Keith Lynn
Ranch Hand
Joined: Feb 07, 2005
Posts: 2341
|
|
That looks like you have an older version of the .class file you are trying to run. Are you sure that you are interpreting the right class?
|
 |
Tontang Bei
Ranch Hand
Joined: Oct 21, 2006
Posts: 130
|
|
|
Yes, Am I the only one getting this exception. could someone else verify for me please?
|
 |
Keith Lynn
Ranch Hand
Joined: Feb 07, 2005
Posts: 2341
|
|
I don't get that exception. Make sure that there is no older version of MainApplication.class in your current directory and try
|
 |
 |
|
|
subject: Exception
|
|
|