This code works below but i want to do it with out a repeater because I only return one row in my query. How would i do this with out a repeater?
aspx.cs page
Display.aspx page
aspx.cs page
C#:
Picture dlPicture = new Picture();
DataTable DTPictures = dlPicture.GetRandomPicture();
rpPictureList1.DataSource = DTPictures;
rpPictureList1.DataBind();
Display.aspx page
C#:
<asp:Repeater ID="rpPictureList3" runat="server">
<ItemTemplate>
<img src="Pictures/<%# DataBinder.Eval(Container.DataItem, "PicLoc") %>" alt="new pic" width="150" />
<br />Rating: <%# DataBinder.Eval(Container.DataItem, "PicRating") %>%
</ItemTemplate>
</asp:Repeater>