• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

problem in adding the panel to an applet

 
Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi,
i have been tryin to add the panel to an applet n its givin certain runtime exceptions,n also i have addded a counter 2 count the time which isnt workin.
the runtime exceptions are:
java.lang.ClassCastException:StartupApplet1
at sun.applet.AppletPanel.createApplet(AppletPanel.java.586)
at sun.applet.AppletPanel.runLoader(AppletPanel.java.515)
at sun.applet.AppletPanel.run(AppletPanel.java.293)
at java.lang.Thread.run(Thread.java.:484)
the program code is given below,[not completed]
plz tell me as 2 wht i have 2 use 2 make it work,
thanks in advance,
Smyle
 
Ranch Hand
Posts: 160
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,
I could not understand that your class StartupApplet1 should habe been exentded with Applet class and I have noticed that you not have done this and how are you calling this applet.
Please see your code once again.
jasmine
 
Jasmine kaur
Ranch Hand
Posts: 160
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
reason of class cast exception is that you have not extended your calss with applet class thats why you are getting this exception .Please extend your calss with applet .
Thanks
 
reply
    Bookmark Topic Watch Topic
  • New Topic