Hi all
Got a couple tables that I'm querying to hook up to a datalist.
I'm using an inner join to pull a project description(1) from one table and the images(bunch) from another. All seemed to be right with the world.
I wanted to have the project description in a header template and the images flowing below. The pictures are displayed fine. No project description.
I write virtually no SQL - can anyone see if there's a problem
Code:
cmd_string As String = "Select Images.ImageURL,Images.ImageDescription,Projects.Description from Projects Inner Join Images on Projects.ProjectName = Images.ProjectName Where Images.ProjectName='" & ddlProjectList.SelectedValue & "'"
The datalist is pretty straightforward:
Code:
<asp:Datalist ID="dlProjects" runat="server" RepeatColumns="1">
<HeaderStyle Font-Bold="true" Font-Size="14px" HorizontalAlign="left" />
<HeaderTemplate>
<p>Project Photos<br /><%# Eval("Description") %></p>
</HeaderTemplate>
<ItemTemplate>
<img style="border-bottom:solid 3px #156322;border-right:solid 2px #156322;border-left:solid 2px #156322;border-top:solid 2px #156322; margin:10px;" alt="" src="<%# Eval("ImageURL") %>" /><br />
<span style="padding-left:6px; font-weight:600;"><%#Eval("ImageDescription")%></span>
</ItemTemplate>
</asp:Datalist>
Any help appreciated. Thanks