CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Nov 2004
    Posts
    8

    Displaying Images in Repeater ...

    Hi guys,

    I am facing a problem of displaying images in using Repeater. To express clearly my trouble, I describe it behind:

    I have a table tblPicture created in Microsoft SQL Server 2000. The tblPicture contains only two fields: ID & Picture. So you can see:

    tblPicture:
    ----------------ID : Int
    ----------------Picture : Image


    Could you please give me some suggestions to solve it...I have a headache with it.... Thanks indeed.

  2. #2
    Join Date
    Aug 2004
    Posts
    191

    Re: Displaying Images in Repeater ...

    Create a new ASPX page that takes image ID as a querystring. In the Load event of this page, get the image data from the DB, set the response content type to the MIME type of your image and output the image data.

    In your repeater, add an ImageControl, and set the image URL to the ASPX page created above with the querystring variable set to the desired image ID.
    Last edited by cmiskow; March 21st, 2005 at 02:02 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured