Load sets of records, 4 items at once

bullrott

New Member
I've a question about loading sets of records for a 'slideshow' on my homepage. I'm using ASP.NET, LINQ and C#.This is the markup of the repeater:\[code\]<asp:Repeater ID="rptSlideShow" runat="server"> <ItemTemplate> <div class="slide"> <nav> <ul> <li> <a href="http://stackoverflow.com/questions/14413507/#"> <img src="http://stackoverflow.com/questions/14413507/Content/Images/logo-artica.gif" alt="ARTICA PRODUCTIONS" width="154" height="82" /></a> </li> <li> <a href="http://stackoverflow.com/questions/14413507/#"> <img src="http://stackoverflow.com/questions/14413507/Content/Images/logo-nead.gif" alt="NEAD A GOOD STORY" width="233" height="70" /></a> </li> <li> <a href="http://stackoverflow.com/questions/14413507/#"> <img src="http://stackoverflow.com/questions/14413507/Content/Images/logo-garden.gif" alt="YOUR GARDEN" width="250" height="90" /></a> </li> <li> <a href="http://stackoverflow.com/questions/14413507/#"> <img src="http://stackoverflow.com/questions/14413507/Content/Images/logo-bitmap.gif" alt="Bitmap" width="48" height="54" /></a> </li> </ul> </nav> </div> </ItemTemplate></asp:Repeater>\[/code\]Every 'slide' should contain 4 items. So I need to build sets with records that contain max. 4 records. If for example the last set contains only 2, because there are no more records, it needs to start over and get 2 items from the beginning.Is this doable in C#?Can someone help me with this?
 
Back
Top