Problem in Repeater

Discussion in 'ASP .Net Web Controls' started by Calvin, Dec 7, 2003.

  1. Calvin

    Calvin Guest

    Hi,

    If I have a repeater to display data from a table.
    Consider inside the ItemTemplate, I have a column (<td>)
    that display a icon depending if the Table Column C2 is
    true or not. How could I implement this onto a Repeater?
    Thanks.

    i.e.
    .....
    <td><%# Databinder.Eval(Container.DataItem,"ICON") %></td>
    ...

    this will only show if it is on or not. But I want to show:
    <td><img src="..."></td>


    Thanks again for all help!
    Calvin
     
    Calvin, Dec 7, 2003
    #1
    1. Advertising

  2. <%# Convert.ToBoolean(Databinder.Eval(Container.DataItem,"ICON")) ?
    "htmlcode if true" : "htmlcode if false" %>

    "Calvin" <> ????
    news:065801c3bc6a$2468d070$...
    > Hi,
    >
    > If I have a repeater to display data from a table.
    > Consider inside the ItemTemplate, I have a column (<td>)
    > that display a icon depending if the Table Column C2 is
    > true or not. How could I implement this onto a Repeater?
    > Thanks.
    >
    > i.e.
    > ....
    > <td><%# Databinder.Eval(Container.DataItem,"ICON") %></td>
    > ..
    >
    > this will only show if it is on or not. But I want to show:
    > <td><img src="..."></td>
    >
    >
    > Thanks again for all help!
    > Calvin
     
    Lostinet.Web Support, Dec 8, 2003
    #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. Replies:
    0
    Views:
    901
  2. Replies:
    0
    Views:
    2,930
  3. Replies:
    1
    Views:
    7,069
    Karl Seguin
    Aug 10, 2005
  4. uncensored
    Replies:
    0
    Views:
    847
    uncensored
    Oct 25, 2006
  5. Microsoft

    Repeater inside a Repeater

    Microsoft, Aug 21, 2006, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    227
    Microsoft
    Aug 21, 2006
Loading...

Share This Page