how to refresh the contents of a JPanel
hello, i am new to JAVA SWING and i don't know all its features very well. I need to refresh the contents of a JPanel, which is in a JFrame. I have succesfully used card layout. i have several JPanels in a JFrame.
Now what i need to do is to refresh the contents of only one JPanel. Again at the same time i have a question whether i need to refresh all the JPanels seperately, if i have to do refresh of all the JPanels? My JPanels have different contents in different JPanels. Plz, help me in this regard. i don't understand what to do. I have heard about repaint(), revalidate(), updateUI(). but i don't know the difference that when to use them...?
i have to refresh my JPanel in a regular interval of 1 hour, whether i have to use timers? Plz, help me in am rather confused.
Thanks in advance. Any small help from u will highly be appreciated.