title: java - Swing image not loading
body: <p>Whenever I try to add this image all I get is a blank jFrame. I am hoping some one can tell me what I am doing wrong. Also I have done a system.out.println on the image and it is getting loaded.</p>
  
  <pre><code>        BufferedImage myPicture = ImageIO.read(getClass().getResourceAsStream("image.jpg"));
  
  
          javax.swing.JLabel jLabel2 = new JLabel(new ImageIcon(myPicture));            
          jLabel1.add(jLabel2);
          jLabel1.repaint();
  </code></pre>