c# - Handler Loading Images From DB - Empty Images -


I load images from database I have a simple handler (.aaxx) file for loading purpose in the collar page The image URL simply indicates the handler below.

  image myImage = new Image (); MyImage.ImageUrl = "/../MyHandler.ashx?imageid=" + myImageId;  

The handler image is processed in

  system.Drawing.Ige the requested image = System.Drawing.Image.FromStream (MemoryStream); RequestImage.Save (context.Response.OutputStream, System.Drawing.Imaging.ImageFormat.Png);  

When there is no image in the database, an empty image (cross) is displayed in the calling ASPX page for the requested image ID.

The possible option is to set the view = false;

But I am unable to do this because of calling nature in the ASPX page

I like this How can I hide the image in the scenario?


Comments

Popular posts from this blog

import - Python ImportError: No module named wmi -

Editing Python Class in Shell and SQLAlchemy -

c# - MySQL Parameterized Select Query joining tables issue -