Which template must you provide, in order to display data
in a Repeater control?
Answer Posted / anilkumar
Example for better idea
<asp:Repeater id="Repeater1" runat="server">
<HeaderTemplate>
<table cellpadding="5" cellspacing="2" >
<tr bgcolor=Gray>
<td><b>CustomerName</b></td>
<td><b>Country</b></td>
</tr>
</HeaderTemplate>
<ItemTemplate>
<tr>
<td><%#
DataBinder.Eval(Container.DataItem,"CustomerName") %></td>
<td><%# DataBinder.Eval(Container.DataItem,"Country")
%></td>
</tr>
</ItemTemplate>
<AlternatingItemTemplate>
<tr bgcolor="#ccccff">
<td><%#
DataBinder.Eval(Container.DataItem,"CustomerName") %></td>
<td><%# DataBinder.Eval(Container.DataItem,"Country")
%></td>
</tr>
</AlternatingItemTemplate>
<FooterTemplate>
</table>
</FooterTemplate>
</asp:Repeater>
| Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
Where the assembly is stored in asp.net?
Explain the Session state management options available with ASP.NET?
What is webresource axd?
How can we call webservices in Banking Applications? and where we are using it?
What is viewstate in asp net with example?
We are using Jscriopt validations and at clint site javascript is not running that time validation would work? if yes then how it would behave?
What is difference between cookies and cache?
How can you make sure that web api returns json data only?
What is data binding in asp net?
What ports must be open for DCOM over a firewall? What is the purpose of Port 135?
What are the authentication types in asp.net?
What is event in asp.net?
What does session_start () do?
Explain difference between dataset and recordset?
What are different methods of session maintenance in asp.net?