locked
Displaying images using dynamic data RRS feed

  • Question

  • User-1593135248 posted

    Hi,

    I currently have an ~/Images folder which stores both a thumbnail and full size image for each product. There is a Product table in SQL with a PictureURL column pointing to the path of the thumbnail image.  I can get the image to displays fine using the following in a custom page templatefield. <asp:Image runat="server" ImageUrl='<%# Eval("PictureURL") %>' />  This is good but I lose alot of functionality from the generated page.

    Is there a simple way to display these using the standard dynamic data templates? Any help would be appreciated.

    Cheers

     Paul

    Sunday, December 14, 2008 2:10 AM

All replies

  • User803211825 posted

    When you say "the standard dynamic data templates" are you referring to the use of dynamic controls?

    If so, the example at http://forums.asp.net/t/1357172.aspx may be of help to you.

    You can put a placeholder on your aspx page and then cycle through your database and for each hit you dynamically create a placeholder and can put several things on it:

    possibly an image icon, textboxes for user input and a button that when pushed will call a function and use the data from the corresponding textboxes from that particular dynamically generated placeholder.

    Am I going in the right direction for what you want to do?

    -Danny

    Sunday, December 14, 2008 5:22 AM
  • User-330204900 posted

    Hi Pcaligari,  are you running plain DD from SP1 or have made use of Dynamic Data Futures from codeplex? if not I suggest you have a look at the Futures sample here: Source Code DynamicDataFutures0716.zip

    Also I have some articles on my blog c# Bits here:

    1. Part 1 - FileImage_Edit FieldTemplate
    2. Part 2 - FileImage_Edit FieldTemplate

    Hope this helps [:D]

    Sunday, December 14, 2008 6:51 AM