473,473 Members | 1,954 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Data Repeater

Hi All!
How to use Data Repeater in VB.NET?

Data Fields are
Employee Number
Name
Photo
Date of Joining
Salary

I want to use all the fields in Data Repeater?

TIA
Viswanathan S
Oct 15 '05 #1
1 1980
Repeaters are usually, but not always, formatted as tables.

The tags within the repeater are for the header, item, alternating items,
footer and separator. You can use databinding statements within the repeater
to format the code.

For example...

<asp:Repeater id="Repeater1" runat="server">
<HeaderTemplate>
<table width="800px">
<tr>
<th>
Identifier</th>
<th>
Language</th>
<th>
Content</th>
<th>
Edit</th>
<th>
Delete</th>
</tr>
</HeaderTemplate>
<ItemTemplate>
<tr>
<td><%# DataBinder.Eval(Container.DataItem,"ident") %></td>
<td><%# DataBinder.Eval(Container.DataItem,"lang") %></td>
<td><%# DataBinder.Eval(Container.DataItem,"content") %></td>
<td>
<asp:Button Runat="server" CommandName="edit" Text="Edit"
CommandArgument='<%# DataBinder.Eval(Container.DataItem,"contentid") %>'
ID="Button1" NAME="Button1">
</asp:Button></td>
<td>
<asp:Button Runat="server" CommandName="delete" Text="Delete"
CommandArgument='<%# DataBinder.Eval(Container.DataItem,"contentid") %>'
ID="Button2" NAME="Button2">
</asp:Button></td>
</tr>
</ItemTemplate>
<AlternatingItemTemplate>
<tr bgcolor="#00cccc">
<td><%# DataBinder.Eval(Container.DataItem,"ident") %></td>
<td><%# DataBinder.Eval(Container.DataItem,"lang") %></td>
<td><%# DataBinder.Eval(Container.DataItem,"content") %></td>
<td>
<asp:Button Runat="server" CommandName="edit" Text="Edit"
CommandArgument='<%# DataBinder.Eval(Container.DataItem,"contentid") %>'
ID="Button3" NAME="Button3">
</asp:Button></td>
<td>
<asp:Button Runat="server" CommandName="delete" Text="Delete"
CommandArgument='<%# DataBinder.Eval(Container.DataItem,"contentid") %>'
ID="Button4" NAME="Button4">
</asp:Button></td>
</tr>
</AlternatingItemTemplate>
<FooterTemplate>
</table>
</FooterTemplate>
</asp:Repeater>

Also.Please will you NOT CROSSPOST!

--
Bob Powell [MVP]
Visual C#, System.Drawing

Ramuseco Limited .NET consulting
http://www.ramuseco.com

Find great Windows Forms articles in Windows Forms Tips and Tricks
http://www.bobpowell.net/tipstricks.htm

Answer those GDI+ questions with the GDI+ FAQ
http://www.bobpowell.net/faqmain.htm

All new articles provide code in C# and VB.NET.
Subscribe to the RSS feeds provided and never miss a new article.

"VIswanathan S" <vi**@ewaksoft.com> wrote in message
news:uy**************@TK2MSFTNGP14.phx.gbl...
Hi All!
How to use Data Repeater in VB.NET?

Data Fields are
Employee Number
Name
Photo
Date of Joining
Salary

I want to use all the fields in Data Repeater?

TIA
Viswanathan S

Oct 15 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: mark | last post by:
My problem is I need to have a "nested" repeater. I have an array which I load into a hashtable - that part works great. I can setup the second repeater to work just fine, as long as it's not...
2
by: John Holmes | last post by:
I am using radioButton controls in a data repeater and would like to incorporate the 'key' field into the 'id' attribute of the radioButton controls and name them something like: 'rad' + '<%#...
2
by: Steve | last post by:
Hi All I am trying to find a way of displaying data in a datatable in such a way that ALL rows (only about 5 - 10) are editable and are updated from a single button press. I thought the best way...
8
by: darrel | last post by:
*sigh*...I've asked this before, but have long forgotten the answer. In the past, I'd often use repeater controls, bind data to it, and then reference the data fields from within the repeater: ...
4
by: Joel | last post by:
Hey all- I'm new to asp.net so please bear with me -- I'm attempting to reference the repeater's Container.DataItem outside the repeater object. In other words -- In a seperate sub routine:...
7
by: charliewest | last post by:
Hello - I'm using a Repeater control to render information in a very customized grid-like table. The Repeater control is binded to a DataSet with several records of information. Within the...
1
by: jeremystein | last post by:
With nested repeaters, how can I access the outer repeater's DataItem from the inner repeater? Here's a snippet from my aspx: <asp:repeater id="OuterRepeater" runat="server"...
1
by: VIswanathan S | last post by:
Hi All! How to use Data Repeater in VB.NET? Data Fields are Employee Number Name Photo Date of Joining Salary
3
by: Emma Middlebrook | last post by:
Hi there, I've been trying to implement a repeater control in an ASP.NET 2 page but I can't seem to get the layout exactly how I want and I'm not sure if it's something that I am doing wrong or...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.