Display Image from Database in an Image control

Discussion in 'ASP .Net Web Services' started by chrispragash@hotmail.com, Aug 25, 2005.

  1. Guest

    Hello Everybody,

    I have a server control that stores an image in the database as an
    image datatype. I would like to display this image (may be in an image
    control) along with other text in a page. What is the best way to
    achieve this functionality. Thanks for all the help in advance.

    Regards,
    Chris
    , Aug 25, 2005
    #1
    1. Advertising

  2. Aidy Guest

    I'd have a ViewImage.aspx page that accepts the ID of the image to store in
    your DB then have that page access the image and right it to the response
    stream. Your page would then construct tags like

    <img src="ViewImage.aspx?ID=123">

    Ideally you should store the images on the file system and the path of the
    images in the DB.

    <> wrote in message
    news:...
    > Hello Everybody,
    >
    > I have a server control that stores an image in the database as an
    > image datatype. I would like to display this image (may be in an image
    > control) along with other text in a page. What is the best way to
    > achieve this functionality. Thanks for all the help in advance.
    >
    > Regards,
    > Chris
    >
    Aidy, Aug 25, 2005
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Sandi
    Replies:
    3
    Views:
    1,759
    Natty Gur
    Nov 6, 2003
  2. Olav Tollefsen

    How to display image blob from database?

    Olav Tollefsen, Apr 25, 2004, in forum: ASP .Net
    Replies:
    2
    Views:
    1,384
    =?Utf-8?B?QmlsbCBCb3Jn?=
    Apr 25, 2004
  3. =?Utf-8?B?U1M=?=
    Replies:
    3
    Views:
    3,830
    Juan T. Llibre
    May 15, 2005
  4. Imran Aziz
    Replies:
    4
    Views:
    1,513
    Imran Aziz
    Aug 11, 2005
  5. Replies:
    1
    Views:
    1,259
    Metalore
    Oct 18, 2006
Loading...

Share This Page