Julien,
In the ItemDataBound event of the repeator you could mark the item as not
being visible:
protected void Repeater1_ItemDataBound(
object sender, RepeaterItemEventArgs e)
{
if (e.Item.ItemType == ListItemType.Item
|| e.Item.ItemType == ListItemType.AlternatingItem)
{
string A = (string)((DataRowView)e.Item.DataItem).Row["A"];
string B = (string)((DataRowView)e.Item.DataItem).Row["B"];
if (A == B)
{
e.Item.Visible = false;
}
}
}
Would that work for you?
Regards,
Rob
"Julien Sobrier" <ju****@sobrier.netwrote in message
news:45***********************@news.sonic.net...
Hello,
I would like to skip the display of some items of a repeater. I think I
need to do something like this:
<asp:Repeater ...>
<ItemTemplate>
<% if (a == b) { %>
...
<% } %>
</ItemTemplate>
</asp:Repeater>
But I can't find out the exact syntax, or if there is a better way to do
that.
Thank you
Julien