This is the error in the java-console:
java.lang.NoClassDefFoundError: /applets/TestApplet (wrong name: TestApplet)
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at sun.applet.AppletClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.applet.AppletClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.applet.AppletClassLoader.loadCode(Unknown Source)
at sun.applet.AppletPanel.createApplet(Unknown Source)
at sun.plugin.AppletViewer.createApplet(Unknown Source)
at sun.applet.AppletPanel.runLoader(Unknown Source)
at sun.applet.AppletPanel.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
what do I wrong?
regards,
K
The browser JVM cannot find your applet class. Is the fully qualified name
TestApplet (is there a package name?) Are the class files / jar in the right
place. Show the HTML (applet tag at least) so we can see if you've
configured it correctly.
Cheers,
Matt Humphrey ma...@iviz.com http://www.iviz.com/
<applet CODE="/applets/TestApplet.class" WIDTH="400" HEIGHT="300">
</applet>
there is no package-declaration in TestApplet.java
regards,
K
>java.lang.NoClassDefFoundError: /applets/TestApplet (wrong name: TestApplet)
Make sure you used package "applets" and class "TestApplet"
consistently spelled including case, both inside the source, on the
file names, and in your Applet params.
See
http://mindprod.com/jgloss/errormessages.html#NOCCLASSDEFFOUNDERROR
--
Canadian Mind Products, Roedy Green.
Coaching, problem solving, economical contract programming.
See http://mindprod.com/jgloss/jgloss.html for The Java Glossary.
No time to help with your problem Kristoffel
(it seems you've got some assistance already),
but I will leave you with one thought..
'An URL paints a thousand words'
When asking for help with an applet, it is so
much easier when the helpers can _surf to_
the applet.
--
Andrew Thompson
http://www.AThompson.info/
http://www.PhySci.org/
http://www.1point1C.org/
> java.lang.NoClassDefFoundError: /applets/TestApplet (wrong name: TestApplet)
You need to set the "applets" directory as the codebase. The code
attribute take a fully qualified class name, and yours is just
"TestApplet".