Results 1 to 2 of 2
  1. #1
    syferite is offline Member
    Join Date
    Oct 2009
    Rep Power

    Default How to put an image on a JPanel

    sorry, close please
    Last edited by syferite; 01-21-2010 at 12:29 PM.

  2. #2
    hardwired's Avatar
    hardwired is offline Senior Member
    Join Date
    Jul 2007
    Rep Power


    Java Code:
    public Login() {
        // This is okay but I don't see where you added it to your app.
        JPanel panel = new BackgroundPanel();
    If you are going to extend JPanel
    Java Code:
    public class Login extends JPanel {
    you could load the image and draw it in Login.

Similar Threads

  1. how to put a background image in a JPanel
    By yanipao in forum New To Java
    Replies: 5
    Last Post: 10-21-2009, 03:27 PM
  2. How can I add image to a JPanel using netbeans
    By shahid0627 in forum AWT / Swing
    Replies: 5
    Last Post: 09-01-2009, 08:56 AM
  3. Add Image to JPanel
    By Seonix in forum AWT / Swing
    Replies: 1
    Last Post: 08-12-2009, 02:54 PM
  4. Image appear at random co-ord within jpanel
    By IHateNetbeans in forum New To Java
    Replies: 1
    Last Post: 04-30-2009, 08:06 PM
  5. how to set image to a jpanel
    By masa in forum AWT / Swing
    Replies: 1
    Last Post: 03-02-2009, 09:36 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts