• Post Reply Bookmark Topic Watch Topic
  • New Topic

Any way to see if an image is null?  RSS feed

 
Darrin Smith
Ranch Hand
Posts: 276
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a bunch of images on a JSP that I set (imageName.setValue(URL)) at run time to point to a servlet that reads the image data from a database. Sometimes, there will be no image stored in the database. When this happens, I get the old red X in the upper left hand corner. Well, I don't really like that red X, and instead of having my servlet send back a default image, I was wondering if there is a way to inspect the HtmlGraphicImage.

This should be simple, but I can't see how to do it as it looks like none of the getXXXX methods get the raw image data (only return the URL string).

So, is there a way to do this, or should I just send back a default image since my servlet does know when the image is null?

Thanks!
[ June 17, 2005: Message edited by: Darrin Smith ]
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!