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

swing doubt

 
Rahul Bharadwaj
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have created a GUI for a tax invoice system in swing...the requirement states that this is not to be allowed to be resizeable. My problem is that when the GUI comes up i see a blank window, and only when i change the window size (by ignoring the requirement ) all the components show up.I call the repaint() method also...still doesn't work. Am i missing something??
 
Mathias Nilsson
Ranch Hand
Posts: 367
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you tried


JFrame.pack()
 
memati bas
Ranch Hand
Posts: 85
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Write setVisible(true) after adding all the components(or containers) into your Top Level Container(JFrame).

Regards
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic