• 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

Can you add a menu to an applet?

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi I'm a part time Java Lecturer, I'm SCJP, SCWCD qualified but unable to do the above!!
Its causing me a little embarrassment because it is part of an assignment my students are doing! Can someone tell me if it is possible, and if so, How?
Thanks very much
Richard Mackney
 
Bartender
Posts: 4121
IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The only way (that I know...) to show a realMenuBar in an Applet(AWT) is to launch a Frame from the Applet and show the MenuBar on it. If you are using a JApplet(Swing) you can add a JMenuBar directly to it.

You can also "fake" the functionality of a MenuBar in an AWT Applet by using PopupMenus... the following code illustrates the use of PopupMenus in an Applet:
reply
    Bookmark Topic Watch Topic
  • New Topic