ASPX页代码:
<asp:Repeater ID= "Repeater1 " runat= "server ">
<HeaderTemplate>
<table width= "100% " border= "0 " cellpadding= "1 " cellspacing= "1 " bgcolor= "#C4CACD ">
<tr>
<td height= "22 " bgcolor= "#F2F4F6 "> <input class= "selFlag " name= "checkbox " type= "checkbox " title= "全选 " onclick= "CheckAll( 'form1 ',this.checked) " value= "checkbox " /> </td>
<td height= "22 " align= "center " bgcolor= "#F2F4F6 "> Username </td>
<td align= "center " bgcolor= "#F2F4F6 "> ParentID </td>
<td align= "center " bgcolor= "#F2F4F6 "> Code </td>
<td align= "center " bgcolor= "#F2F4F6 "> GroupID </td>
<td align= "center " bgcolor= "#F2F4F6 "> GroupCode </td>
</tr>
</HeaderTemplate>
<ItemTemplate>
<tr>
<td bgcolor= "#FFFFFF "> <input type= "checkbox " class= "selFlag " id= "selID " value= " <%#DataBinder.Eval(Container.DataItem, "id ")%> " runat= "server " enableviewstate= "true " /> </td>
<td height= "20 " bgcolor= "#FFFFFF "> <%#DataBinder.Eval(Container.DataItem, "Username ")%> </td>
<td bgcolor= "#FFFFFF "> <%#DataBinder.Eval(Container.DataItem, "ParentID ")%> </td>
<td bgcolor= "#FFFFFF "> <%#DataBinder.Eval(Container.DataItem, "Code ")%> </td>
<td bgcolor= "#FFFFFF "> <%#DataBinder.Eval(Container.DataItem, "GroupID ")%> </td>
<td bgcolor= "#FFFFFF "> <%#DataBinder.Eval(Container.DataItem, "GroupCode ")%> </td>
</tr>
</ItemTemplate>