How can I check if the Image I would like to load in the ImagePanel exist?
I am using this code to show a image in the panel after selecting an item from a multilist.
try {
imagePanel1.setImageURL(new java.net.URL(" 0)+".jpg");
}
catch (java.net.MalformedURLException error) { }
catch(java.beans.PropertyVetoException e) { }
try {
imagePanel1.setStyle(symantec.itools.awt.ImagePanel.IMAGE_CENTERED);
}
catch(java.beans.PropertyVetoException e) { }
imagePanel1.setLayout(null);
If the image don't exist the imagePanel is blank. I would like to give the user the opportunity to add a picture if the image don't exist, but then i need to know wethever the image exist og not.
Jørn Arild Andenæs
I am using this code to show a image in the panel after selecting an item from a multilist.
try {
imagePanel1.setImageURL(new java.net.URL(" 0)+".jpg");
}
catch (java.net.MalformedURLException error) { }
catch(java.beans.PropertyVetoException e) { }
try {
imagePanel1.setStyle(symantec.itools.awt.ImagePanel.IMAGE_CENTERED);
}
catch(java.beans.PropertyVetoException e) { }
imagePanel1.setLayout(null);
If the image don't exist the imagePanel is blank. I would like to give the user the opportunity to add a picture if the image don't exist, but then i need to know wethever the image exist og not.
Jørn Arild Andenæs