Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Sub JPanel Size

 
Behrouz Hosseini
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Every one,
I am trying to add some panels to my main Jpanel . I have three simple class as below. Every thing works fine except that I can not set the sub JPanels(pan1,pan2,pan3) size!
1-Class MyPanel
2-Class MyFrame
3-Class Main
I tried the setPreferredSize() method as well, but it did not work! Could you please let me know what I am doing wrong!?


Best Regards
 
Michael Dunn
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
> I tried the setPreferredSize() method as well, but it did not work!

worked OK for me
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic