Solved

Java Applet not loading in browser

Posted on 2010-11-29
5
307 Views
Last Modified: 2012-05-10
I used an existing working java checkers applet game.  It had:
Checkers.class
ConsoldeCanvans.class
ConsolePanle.class
ConsoleApplet.class
and some other class files:
example: Checkers$Board.class

also supplied was the Checkers.java

I created a project in NetBeans call "javachekcers" , added the class files and been editing the Checkers .java file but when I recompiled it and uplaoded all the class files to the web server the applet no longer works (I can run it in debug in NetBeans).

I found lots of suggestion about the html code attribute of the applet tag, but haven't been able to get to work: <applet code="javacheckers.Checkers" width="350" height="250" alt="(Applet 'Checkers' should be displayed here.)"> is what i currently use to call it.

and the applet is here: http://www.e3pro.com/test/test1.html

Here is the first of many errors: java.lang.NoClassDefFoundError: Checkers (wrong name: javacheckers/Checkers)
 
Suggestions?

thanks!
Christa
0
Comment
Question by:christamcc
  • 3
5 Comments
 
LVL 86

Accepted Solution

by:
CEHJ earned 500 total points
Comment Utility
Your package is probably wrong. It needs to be (in relation to where the html is)

./javacheckers/Checkers.class
0
 
LVL 86

Expert Comment

by:CEHJ
Comment Utility
The code should be available at

http://www.e3pro.com/test/javacheckers/Checkers.class

and the package declaration in the source should be

package javacheckers;
0
 
LVL 16

Expert Comment

by:Valeri
Comment Utility
0
 

Author Closing Comment

by:christamcc
Comment Utility
oh, man!  My savior!  and speedy... :)  Thank you!
0
 
LVL 86

Expert Comment

by:CEHJ
Comment Utility
:)
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Suggested Solutions

For customizing the look of your lightweight component and making it look lucid like it was made of glass. Or: how to make your component more Apple-ish ;) This tip assumes your component to be of rectangular shape and completely opaque. (COD…
Java contains several comparison operators (e.g., <, <=, >, >=, ==, !=) that allow you to compare primitive values. However, these operators cannot be used to compare the contents of objects. Interface Comparable is used to allow objects of a cl…
The viewer will learn how to implement Singleton Design Pattern in Java.
This video teaches viewers about errors in exception handling.

771 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now