I'm trying to display two pictures on my JFrame, the way I found was to use icons and JLabels, this seems pretty straightforward and I'm not having problems with this. But when it comes to locating the image I can't get it to work. I'm on a linux machine thus the forwardslash style. I created a folder called pics in my project which is called 399assig1.
ImageIcon icon1 = createImageIcon("/home/dsk03/ugrad/jeanbern/workspace/C291/workspace/399assig1/pics/fur-05.jpg","First");
this.label1 = new JLabel("Picture 1", icon1, JLabel.CENTER);
ImageIcon icon2 = createImageIcon("pics/fur.png","Second");
this.label2 = new JLabel("Picture 2", icon2, JLabel.CENTER);
this is the error I get
Couldn't find file: /home/dsk03/ugrad/jeanbern/workspace/C291/workspace/399assig1/pics/fur-05.jpg
Couldn't find file: pics/fur.png