This week's book giveaway is in the OCPJP forum. We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line! See this thread for details.
Why do I get this error? Is it due to the JDK version? I used JDK1.5. Is'nt Java backward compatible? It executed fine on my machine, but gave me the above error on a different machine. By the way, the exception occured while initializing an applet.
If you compile with JDK 1.5, by default, the class files will not work with older JDKs. Older class files will work with JDK 1.5. You can use the -target switch to generate code for older JVMs, but then you can't use any nw language features.