You can loop through the items that are displayed in the datagrid.
foreach (DataGridItem item in MyDataGrid.Items)
{
if(item.ItemType == ListItemType.Item || item.ItemType ==
ListItemType.AlternatingItem)
{
item.Cells[0].Text = "blah";
}
}
Hope that helps,
Andrew
-----Original Message-----
From: Chris [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 16, 2003 12:40 PM
To: dotnet
Subject: Modify just the visible rows in paged datgrid?
A dataset is being displayed in a standard paged datagrid control.
Part of the displayed data has to be processed on-the-fly
(HTML-formatted with hot links to display in a templated column of the
datagrid.) Currently, it is being processed by looping through the
dataset just prior to binding it to the datagrid. However if the
dataset became large over time, we'd be wasting resources on HTML
formatting many rows that won't be visible in the datagrid.
Is there a clever way of determining which rows in the dataset are going
to be visible in the currently-requested page of the datagrid? If not,
has anyone who has done this the hard way willing to share code or
advice?
Any other ideas welcome too.
TIA
---
You are currently subscribed to dotnet as: [EMAIL PROTECTED] To
unsubscribe send a blank email to %%email.unsub%%
---------
Administrated by 15 Seconds : http://www.15Seconds.com
List Archives/Search : http://local.15Seconds.com/search Subscription
Information : http://www.15seconds.com/listserv.htm
Advertising Information: http://www.internet.com/mediakit/
---
You are currently subscribed to dotnet as: [email protected]
To unsubscribe send a blank email to [EMAIL PROTECTED]
---------
Administrated by 15 Seconds : http://www.15Seconds.com
List Archives/Search : http://local.15Seconds.com/search
Subscription Information : http://www.15seconds.com/listserv.htm
Advertising Information: http://www.internet.com/mediakit/