使用 Repeater 控件,每隔N条数据输出另外的格式

类似某些新闻网站一样,每隔5条数据输出一行 ............. 的分隔符,可以这样写。 

<ItemTemplate>
<%#(Container.ItemIndex + 1) % 5 == 0 && Container.ItemIndex != 0 ? "<div class=\"line\"> </div>" : String.Empty%>
</ItemTemplate>
posted @ 2011-02-10 20:39  geass..  阅读(315)  评论(0编辑  收藏  举报