aspx_beginners thread: Container.DataItem("Title") throws error using C# not with vb?
Just started playing with this dotNet stuff, came across a strange problem
I am binding a recordset to this datalist in the Page_Load event.
Does anyone know why this will throw an error when using C#?
It runs fine in vb.
If i remove the <%# Container.DataItem("Title") %> line then it works in
C#.
<asp:DataList id="list" runat="server">
<ItemTemplate>
<b>Testing:</b><br>
<%# DataBinder.Eval(Container.DataItem, "Title") %><br>
<%# Container.DataItem("Title") %><br>
</ItemTemplate>
</asp:DataList>
Any ideas?