This week's book giveaway is in the Other Languages forum.
We're giving away four copies of Functional Reactive Programming and have Stephen Blackheath and Anthony Jones on-line!
See this thread for details.
Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Jpanel not displayed

 
mark smith
Ranch Hand
Posts: 257
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi

in a class i do



code of this class


nothing is displayed... any idea?

thanks
 
Moojid Hamid
Ranch Hand
Posts: 120
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You need a "Top-Level Container"
 
Michael Dunn
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
and you also need to add the tabbedPane to its container (the class TestPanel)
 
mark smith
Ranch Hand
Posts: 257
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ok so every jpanel need to be added in a jframe?
 
Rob Spoor
Sheriff
Pie
Posts: 20667
65
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic