File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Swing / AWT / SWT and the fly likes Jpanel not displayed Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Jpanel not displayed" Watch "Jpanel not displayed" New topic
Author

Jpanel not displayed

mark smith
Ranch Hand

Joined: Apr 05, 2005
Posts: 250
hi

in a class i do



code of this class


nothing is displayed... any idea?

thanks
Moojid Hamid
Ranch Hand

Joined: Mar 07, 2009
Posts: 120
You need a "Top-Level Container"
Michael Dunn
Ranch Hand

Joined: Jun 09, 2003
Posts: 4632
and you also need to add the tabbedPane to its container (the class TestPanel)
mark smith
Ranch Hand

Joined: Apr 05, 2005
Posts: 250
ok so every jpanel need to be added in a jframe?
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19670
    
  18

Or another control like a second JPanel, a JTabbedPane or a JScrollPane. But in the end, all controls must be directly or indirectly added to a (J)Frame, (J)Dialog, (J)Window or (J)Applet.


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
 
 
subject: Jpanel not displayed