This week's book giveaway is in the OCAJP 8 forum.
We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line!
See this thread for details.
The moose likes Swing / AWT / SWT and the fly likes How to reset JPanel in java Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "How to reset JPanel in java" Watch "How to reset JPanel in java" New topic
Author

How to reset JPanel in java

pooja prabhu
Ranch Hand

Joined: Sep 23, 2012
Posts: 33
How to reset JPanel and JTabedPane in java??? Can anyone help
Darryl Burke
Bartender

Joined: May 03, 2008
Posts: 5048
    
  10

What does it mean to you to 'reset' a JPanel or a JTabbedPane?


luck, db
There are no new questions, but there may be new answers.
pooja prabhu
Ranch Hand

Joined: Sep 23, 2012
Posts: 33
When i click on button..... tabs are created with JPanel..tabs values are taken from database......When i click on button for 2nd time all contents from jpanel should clear and new values should be uploaded
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 20136
    
  30

What have you tried so far?


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6 - OCEJPAD 6
How To Ask Questions How To Answer Questions
pooja prabhu
Ranch Hand

Joined: Sep 23, 2012
Posts: 33
I have tried JPanel.removeAll(); Jpanel.revalidate and JPanel.repaint
Michael Dunn
Ranch Hand

Joined: Jun 09, 2003
Posts: 4632
Why would you remove the components that
display the db values?

change the text for labels/textfields etc.
or change the model for tables/comboBoxes etc.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to reset JPanel in java
 
It's not a secret anymore!