Is it possible to add a menubar to one of the windows in a tabbed pane? And is a frame the only container which can have a menubar?
Though you can directly add a JMenubar in to a JtabbedPane as both are JComponents. But it wont look nice(usable), if you have tried it.
I would suggest to subclass BasicTabbedPaneUI
and override installComponents(),
there you can add you JmenuBar at the top or wherever you want.
Is it possible to add a menubar to one of the windows in a tabbed pane?
What problem did you have when you tried to do this?
If you need more help post your SSCCE showing the problem.
As Suraj mentioned, you can force the issue as as they are both, both components and containers however you will have to do the extra work to organize it in your pane's layout along with the rest of the components in the pane -- unlike with a JFrame which has methods to support it outright (setJMenuBar and you're outta there). Normally, when added to a JFrame, the JMenuBar is not in the content pane, it is in a layered pane which contains both the menu bar and the content pane below it.
You might also want to consider using a JToolBar which is very flexible (more easily customized) and has some optional built-in goodies like being separable/dockable.