Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Java Client Applet - Incompatible Magic Value

Posted on 2010-08-18
4
Medium Priority
?
638 Views
Last Modified: 2012-08-13
Sometimes I ask my friends to try out my applet and some get in and it works FINE for them... and for others... they get this error ...

java.lang.ClassFormatError: Incompatible magic value 1008813135 in class file tileGen
	at java.lang.ClassLoader.defineClass1(Native Method)
	at java.lang.ClassLoader.defineClassCond(Unknown Source)
	at java.lang.ClassLoader.defineClass(Unknown Source)
	at java.security.SecureClassLoader.defineClass(Unknown Source)
	at sun.plugin2.applet.Applet2ClassLoader.findClass(Unknown Source)
*	at java.lang.ClassLoader.loadClass(Unknown Source)
	at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unknown Source)
	at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
	at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
	at java.lang.Thread.run(Unknown Source)

Open in new window


Maybe it's because I compiled with the latest version of java and the friends are used an outdated java? maybe? What do you think?

thanks.
0
Comment
Question by:UrbanTwitch
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 92

Accepted Solution

by:
objects earned 2000 total points
ID: 33471491
yes that error is caused by comiling for a later version of java than it is being run with
you can use the javac switchs -target -source to control what version class file is produced
0
 
LVL 5

Author Comment

by:UrbanTwitch
ID: 33471497
What would be a good version to compile at? 1.5?
0
 
LVL 92

Expert Comment

by:objects
ID: 33471506
actually that value suggests its a corrupt class file that is being used.
might be worth getting them to clear there java cache and reload the applet

> What would be a good version to compile at? 1.5?

1.5 is a good choice
to do that you need to make sure you're not using any 1.6 features.
0
 
LVL 5

Author Comment

by:UrbanTwitch
ID: 33471549
Well then, my tileGen probably is because my friend who had the error got another error... so yeah.. either update or don't play. thanks.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Are you developing a Java application and want to create Excel Spreadsheets? You have come to the right place, this article will describe how you can create Excel Spreadsheets from a Java Application. For the purposes of this article, I will be u…
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
Viewers learn about the scanner class in this video and are introduced to receiving user input for their programs. Additionally, objects, conditional statements, and loops are used to help reinforce the concepts. Introduce Scanner class: Importing…
Viewers will learn about if statements in Java and their use The if statement: The condition required to create an if statement: Variations of if statements: An example using if statements:
Suggested Courses

715 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question