Posted on 1998-08-24
Medium Priority
Last Modified: 2011-10-03
What's the reason for the following error message of the Navigator?

# Applet debug level set to 9
# stopApplet: contextID=2 appletID=13800992 parentMWContext=13682640
# Stopping applet: pm, appletID=13800992, contextID=2
# destroyApplet: contextID=2 appletID=13800992
# Destroying applet: pm, appletID=13800992, contextID=2
#     total applets=1
#   destroying context for contextID 2
# Destroying applet context: http://Storm/Pm/pm.html, contextID=2
# Destroying AppletFrame without disposing: netscape.applet.DerivedAppletFrame[frame2,0,0,850x300,hidden,layout=java.awt.BorderLayout,resizable,title=]
#   frameMWContext=13682640
# Destroying all applets: http://Storm/Pm/pm.html, contextID=2
# initApplet: contextID=2 appletID=13771952 parentContext=13682640 frameContext=13682640
# New applet context: http://Storm/Pm/pm.html, contextID=2
# Initializing applet: pm.class, appletID=13771952, contextID=2
#   docURL=http://Storm/Pm/pm.html reloadClasses=true
#     total applets=2
#     New applet: 13771952 at http://Storm/Pm/ width=850 height=300 hspace=0 vspace=0 align=baseline codebase=http://Storm/Pm/ code=pm.class
# startApplet: contextID=2 appletID=13771952 newFrameMWContext=13682640
# Starting applet: pm, appletID=13771952, contextID=2
#   preventing reuse of netscape.applet.AppletClassLoader@800cda6
#   new class loader netscape.applet.AppletClassLoader@8008b86
#      context = netscape.applet.MozillaAppletContext@800d660
#      codebase = http://Storm/Pm/
# Loading class pm
# Fetching http://Storm/Pm/pm.class
# Destroying AppletFrame without disposing: netscape.applet.DerivedAppletFrame[frame2,0,0,850x300,hidden,layout=java.awt.BorderLayout,resizable,title=]
# Applet exception: error: java.lang.ClassFormatError: Wrong class name inside class file
java.lang.ClassFormatError: Wrong class name inside class file
  at java.lang.ClassLoader.defineClass(Compiled Code)
  at netscape.applet.AppletClassLoader.loadClass(Compiled Code)
  at netscape.applet.AppletClassLoader.findClass(Compiled Code)
  at netscape.applet.AppletClassLoader.loadClass1(Compiled Code)
* at netscape.applet.AppletClassLoader.loadClass(Compiled Code)
  at netscape.applet.AppletClassLoader.loadClass(Compiled Code)
  at netscape.applet.DerivedAppletFrame$LoadAppletEvent.dispatch(Compiled Code)
  at java.awt.EventDispatchThread$EventPump.dispatchEvents(Compiled Code)
  at java.awt.EventDispatchThread.run(Compiled Code)
  at netscape.applet.DerivedAppletFrame$AppletEventDispatchThread.run(Compiled Code)

Using JBuilder 2 and the AppletViewer the program runs well.
Maybe it's important that I have all class files in a directory called "pm" since all the files of the program should belong to the package pm.
Question by:dirku
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

Author Comment

ID: 1222437
Edited text of question

Accepted Solution

diakov earned 80 total points
ID: 1222438
- Carefully check the upper-lower case of the names of the files. Usually the local file system is case insensitive, but the web servers are. Especially when they run UNIX. When moving, copying, etc, check the file names with a good program. For example the command prompt with settings to show the case, or Windows Explorer.
- The package structure is similar to a directory structure. The subpackages has to be in the corresponding directories. This is how the loader finds them.

Author Comment

ID: 1222439
Silly mistake! I really needed to change CODE="pm/pm.class" to CODE="pm/PM.class" ...


Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

INTRODUCTION Working with files is a moderately common task in Java.  For most projects hard coding the file names, using parameters in configuration files, or using command-line arguments is sufficient.   However, when your application has vi…
Java functions are among the best things for programmers to work with as Java sites can be very easy to read and prepare. Java especially simplifies many processes in the coding industry as it helps integrate many forms of technology and different d…
The viewer will learn how to implement Singleton Design Pattern in Java.
This video teaches viewers about errors in exception handling.
Suggested Courses
Course of the Month8 days, 7 hours left to enroll

766 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