How do I assign a variable to a container.dataitem in repeater control

Discussion in 'ASP .Net Web Controls' started by Chumley the Walrus, May 12, 2004.

  1. I need to assign a variable to a record drawn from a db by way of a
    repeater control:


    <ASP:Repeater id="thedata" runat="server">

    <itemtemplate>
    <%dim display

    display = Container.DataItem("displaygroup") %>

    <%# Container.DataItem("displaygroup")%>

    </ItemTemplate>
    </ASP:Repeater>

    the display = Container.DataItem("displaygroup") does not work (error:
    Name 'Container' is not declared.), and i need to find a way to assign
    what's in <%# Container.DataItem("displaygroup")%> a variable

    thanks
    chum
     
    Chumley the Walrus, May 12, 2004
    #1
    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. Earl Teigrob
    Replies:
    0
    Views:
    454
    Earl Teigrob
    Jul 7, 2004
  2. Patrick.O.Ige
    Replies:
    0
    Views:
    602
    Patrick.O.Ige
    Mar 16, 2006
  3. abargaddon
    Replies:
    2
    Views:
    23,040
    abargaddon
    Feb 2, 2008
  4. Joe Rattz
    Replies:
    2
    Views:
    618
    Robert Koritnik
    Sep 10, 2004
  5. Replies:
    0
    Views:
    133
Loading...

Share This Page