Creating a Menu Bar

See Also

  1. In the Palette window, click a menu bar component:
    icon for JMenuBar - JMenuBar from the Swing components
    icon for MenuBar - MenuBar from the AWT components
  2. Click anywhere in the JFrame, JDialog, or JApplet container to which you want to add the menu bar.

    If this is the first menu bar you have added to the form, the menu bar appears visually on the form.

    If this is not the first menu bar on the form, the menu appears under the Other Components node in the Inspector window. The menu does not appear visually on the form.

Tip Only the AWT MenuBar can be used as the main menu for AWT forms, and only the JFC/Swing JMenuBar can be used as the main menu for JFC/Swing forms.
See Also
Adding a Component to a Form

Changing the Current Menu Bar
Adding a Menu to a Menu Bar
Creating a Contextual Menu
Adding a Menu Item
Adding an Event Handler to a Menu Item

Legal Notices