Repeater Control - ASP.NET

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • ra220511
    New Member
    • Oct 2007
    • 11

    Repeater Control - ASP.NET

    I havnt a lot of experience with repeater controls but basically what im tryin to do is to place data into a number of text boxes. the information is loaded from the database and will change every time the repeater is reloaded. i have all that part working but my problem is how do i place the data into the text box



    this is inside the repeater

    <asp:TextBox runat="server" ID="txtTitle" Width="200px"></asp:TextBox>

    i was hoping it would just be

    <asp:TextBox runat="server" ID="txtTitle" Width="200px" text=<%#Eval("D VDTitle")%>></asp:TextBox>

    any one know how its done
    Last edited by jhardman; Jan 14 '08, 06:52 AM. Reason: moved to .NET forum - ASP forum is for "classic" ASP
  • ilearneditonline
    Recognized Expert New Member
    • Jul 2007
    • 130

    #2
    Originally posted by ra220511
    I havnt a lot of experience with repeater controls but basically what im tryin to do is to place data into a number of text boxes. the information is loaded from the database and will change every time the repeater is reloaded. i have all that part working but my problem is how do i place the data into the text box



    this is inside the repeater

    <asp:TextBox runat="server" ID="txtTitle" Width="200px"></asp:TextBox>

    i was hoping it would just be

    <asp:TextBox runat="server" ID="txtTitle" Width="200px" text=<%#Eval("D VDTitle")%>></asp:TextBox>

    any one know how its done
    Do you have a Data Source associated with it? If you are doing it from ASP.NET, then you would have a DataSourceID in your tag.
    [CODE=ASP]
    <asp:Repeater runat="server" ID="rpt" DataSourceID="o bjMovies">
    <ItemTemplate >
    <asp:TextBox runat="server" ID="txtTitle" Text='<%# Eval("DVDTitle" ) %>' /><br />
    </ItemTemplate>
    </asp:Repeater>
    [/CODE]

    Comment

    • ra220511
      New Member
      • Oct 2007
      • 11

      #3
      Originally posted by ilearneditonlin e
      Do you have a Data Source associated with it? If you are doing it from ASP.NET, then you would have a DataSourceID in your tag.
      [CODE=ASP]
      <asp:Repeater runat="server" ID="rpt" DataSourceID="o bjMovies">
      <ItemTemplate >
      <asp:TextBox runat="server" ID="txtTitle" Text='<%# Eval("DVDTitle" ) %>' /><br />
      </ItemTemplate>
      </asp:Repeater>
      [/CODE]

      No what can this be datasoureid be used for?????????

      Comment

      Working...