I have a problem. I don\'t know how to display an image by clicking a JButton.
I have a class which can show and hide an image:
/** * */ package
1) use JLabel#setIcon() instead of painting image as background to the JFrame
2) create methods into class Selectie
class Selectie
private void setIconToLabel (Icon icon){ myDesiredLabel.setIcon(icon); }
3) don't create a new JFrame for another image use CardLayout instaed