How to display Repeater controls data in 3 different rows of HTML table
I have a Repeater control which is bind to ObjectDataSource. This repeater control contains 3 numeric values.
I want to design HTML table in .aspx page, so that I can show Repeater control's data exactly described as below with hard coded text as 'Temp', 'Depth', 'GOR':
Basic Data
Temp 10
Depth 20
GOR 5
Please let me know how to achieve above design using 1 repeater control.
Below is the HTML code:
<asp:Repeater ID="rptRETarget" runat="server" DataSourceID="odsRETarget">
<ItemTemplate>
<tr style="color: #000000; font-family: Arial, Verdana; font-size: 11px;">
<td align="center" class="slide_td"><%# Eval("Temp") %></td>
<td align="center" class="slide_td"><%# Eval("Depth") %></td>
<td align="center" class="slide_td"><%# Eval("GOR") %></td>
</tr>
</ItemTemplate>
</asp:Repeater>
<asp:ObjectDataSource ID="odsRETarget" runat="server" SelectMethod="ListOfRETargetProjectBrief" TypeName="SLB.App.Project.ODS.Reservoir">
<SelectParameters>
<asp:QueryStringParameter QueryStringField="pid" Type="String" Name="ProjectID" />
<asp:Parameter DbType="Guid" Name="projectVersionId" />
</SelectParameters>
</asp:ObjectDataSource>
Below is the SelectMethod query:
SELECT TARGET_RESERVOIR_ID TargetREID, TARGET_RESERVOIR_DESC TargetREDesc, '' Temp, '' Depth, '' GOR
FROM P_PROJECT_TARGET_RESERVOIR
WHERE TARGET_RESERVOIR_ID NOT IN (
SELECT TARGET_RESERVOIR_ID
FROM P_PROJECT_RE_TARGET_RE
WHERE PROJECT_ID = '45135724-bbc9-4f48-86f8-865996930d4c'
)
AND PROJECT_ID = '45135724-bbc9-4f48-86f8-865996930d4c'
Result of SelectMethod query (when run in Sql server mgmt studio):
----------------------------------------------------------------------------
ID Temp Depth GOR
1 10 20 5
Thank you so much in advance.