Solved

Java Applet not loading in browser

Posted on 2010-11-29
5
310 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
ID: 34229453
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
ID: 34229465
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
ID: 34229485
0
 

Author Closing Comment

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

Expert Comment

by:CEHJ
ID: 34229496
:)
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

For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
Introduction Java can be integrated with native programs using an interface called JNI(Java Native Interface). Native programs are programs which can directly run on the processor. JNI is simply a naming and calling convention so that the JVM (Java…
Viewers learn about the “for” loop and how it works in Java. By comparing it to the while loop learned before, viewers can make the transition easily. You will learn about the formatting of the for loop as we write a program that prints even numbers…
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…

821 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