Repeater: Different StyleSheets for alternating rows

Discussion in 'ASP .Net' started by Sachin, Jun 1, 2007.

  1. Sachin

    Sachin Guest

    Hi All,

    I am using ASP.NET Repeater Web Control.
    I want to use different stylesheets for alternating rows similar to DataGrid
    contorl.
    How can I do this?

    Thanks In Advance
    Sachin
     
    Sachin, Jun 1, 2007
    #1
    1. Advertising

  2. Basic breakdown of what's avaiable:

    <asp:Repeater id="Repeater1" runat="server">
    <HeaderTemplate>
    HTML and binding expressions here
    </HeaderTemplate>
    <ItemTemplate>
    HTML and binding expressions here, CSS style class, e.g.
    <div style="background-color:#E0E0E0"> stuff here </div>
    </ItemTemplate>
    <AlternatingItemTemplate>
    HTML and binding expressions , CSS style class, e.g.
    <div style="background-color:#FFCC66"> alternating stuff here </div>
    </AlternatingItemTemplate>
    <SeparatorTemplate>
    HTML and binding expressions
    </SeparatorTemplate>
    <FooterTemplate>
    HTML and binding expressions
    </FooterTemplate>
    </asp:Repeater>

    Cheers,
    Peter
    --
    Site: http://www.eggheadcafe.com
    UnBlog: http://petesbloggerama.blogspot.com
    Short urls & more: http://ittyurl.net




    "Sachin" wrote:

    > Hi All,
    >
    > I am using ASP.NET Repeater Web Control.
    > I want to use different stylesheets for alternating rows similar to DataGrid
    > contorl.
    > How can I do this?
    >
    > Thanks In Advance
    > Sachin
    >
     
    =?Utf-8?B?UGV0ZXIgQnJvbWJlcmcgW0MjIE1WUF0=?=, Jun 1, 2007
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. MattC
    Replies:
    0
    Views:
    1,592
    MattC
    Mar 22, 2005
  2. Stuart Shay
    Replies:
    3
    Views:
    13,141
    Darkmoor
    Aug 20, 2010
  3. Andries
    Replies:
    5
    Views:
    4,467
    Sean Jorden
    Sep 9, 2003
  4. Replies:
    3
    Views:
    609
  5. MangroveRoot

    alternating text/image rows

    MangroveRoot, Nov 4, 2007, in forum: HTML
    Replies:
    7
    Views:
    428
    Adrienne Boswell
    Nov 4, 2007
Loading...

Share This Page