• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Refresh a frame

 
Jesse Walker
Ranch Hand
Posts: 50
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am trying to use a checkbox that once it is selected, that it will add a component to the frame do I need to use paint and repaint/update or is there another way??
Thank you
Jesse
 
Craig Wood
Ranch Hand
Pie
Posts: 1535
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
 
Brian Cole
Author
Ranch Hand
Posts: 903
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Call revalidate() on the JPanel after you have added the new component.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic