Often, we insert an icon into a JFrame in Java application, but how to insert an icon into JInternalFrame? It's almost the same, it's only need to use different method. We can user setFrameIcon() method.
This is the snippet code
URL url = getClass().getResource(”image/login.gif”);
Icon icon = new ImageIcon(url);
setFrameIcon(icon);
Best regards,
Deny Sutani
No comments:
Post a Comment