C# - Reverse Repeater Order

笑着哭i 提交于 2019-12-23 04:45:38

问题


I am working on an updates page where the user can input updates into the system and all the updates are shown in a repeater control on the same page.

As they are now, the latest update is displayed on the bottom of the page whilst the first update is displayed on top.

Is there a way to reverse the order such that the latest updates in the repeater are always displayed on top? Thanks :)


回答1:


Just change the query which finds "all the updates" so that it returns the results in the descending order. You haven't told us anything about where that data's coming from, but I can't imagine it would be hard to reverse the order. The repeater doesn't need to know about it.



来源:https://stackoverflow.com/questions/9954797/c-sharp-reverse-repeater-order

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!