I am currently reading from my database where i am able to read the location strings and convert them to images that are able to appear on a jframe. I create a JLabel and then change this to an ImageIcon. The code for that is below. How do I put all of these imageicons into one single JPanel. So far, I have only been able to put the image into a separate JPanel and all of these jpanels appear on a jframe as the method iterates over every image that is matched in the database.. Any help would be appreciated
JLabel image = new JLabel(new ImageIcon(pic));
image.setIcon(new ImageIcon(pic));
panel.add(image);
Since a
JPanelby default uses aFlowLayout, you can just use subsequentaddcallsand all images will be added to the panel