Win a copy of Five Lines of Code this week in the OO, Patterns, UML and Refactoring forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

Applet works in browser, but not in Appletviewer

 
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have written my own applets, but Appletviewer won't display them. However, they look fine in my Netscape browser. Note:
1. Appletviewer DOES work with other applets, so it doesn't appear to be a problem with installation.
2. When running Appletviewer with one of my applets, I get the following:
________________
C:\Java> appletviewer my.htm
Exception in thread "main" java.util.MissingResourceException: Can't find resource for bundle sun.applet.resources.MsgAppletViewer, key appletpanel.badattribute.exception
at java.util.ResourceBundle.getObject(ResourceBundle.java:382)
at java.util.ResourceBundle.getString(ResourceBundle.java:382)
at sun.applet.AppletMessageHandler.getMessage(AppletMessageHandler.java:42)
...and a mess more of similar messages.

Any ideas what it is complaining about? I can post the original source code if that would help. Thanks.
 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Tina
Check out the arguments of <Applet> tag. Might be you have not specified the right class name for 'code' attribute.
Deepak
 
Tina Parks
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Actually, I checked all the file names very carefully before posting.
For convenience, I decided to create a new folder. Once I dropped my files into the new folder the appletviewer suddenly began to work. Bizarre! (This folder was simply a subfolder of the original. I have no idea now what the problem was before.)
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Tina,
i was getting the same error. Deepak is right. In my case, it was not the Html tags, but an extra comma
<APPLET CODE="HelloAgainApplet.class" WIDTH=250, HEIGHT=70>
once i took the comma after, "WIDTH=250" out
<APPLET CODE="HelloAgainApplet.class" WIDTH=250 HEIGHT=70>
the 'appletviewer' started working alright.
neeraj singh
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
    Bookmark Topic Watch Topic
  • New Topic