我的DataList分页有什么问题?
我把部分代码贴出来:
页面代码:
<asp:datalist id=DataList1 runat= "server " DataMember= "Message " DataSource= " <%# dataSet21 %> " ShowFooter= "False " DataKeyField= "M_ID " RepeatDirection= "Horizontal " RepeatColumns= "1 " Width= "800px " Height= "96px " CellPadding= "0 ">
<HeaderTemplate>
<FONT face= "宋体 "> 留言列表 </FONT>
</HeaderTemplate>
<EditItemStyle Font-Size= "9pt "> </EditItemStyle>
<ItemStyle Font-Size= "9px "> </ItemStyle>
<ItemTemplate>
<TABLE cellSpacing= "1 " cellPadding= "0 " bgcolor= "#00ccff " width= "800 " align= "center " border= "0 ">
<TR>
<td width= "100px " bgcolor= "#FFFFFF "> <%# DataBinder.Eval(Container, "DataItem.M_GuestName ") %> 的留言 </td>
<TD bgcolor= "#FFFFFF "> <%# DataBinder.Eval(Container, "DataItem.M_Title ") %> </TD>
<TD bgcolor= "#FFFFFF " align= "right ">
<asp:ImageButton id=ibtnDelete runat= "server " Visible= ' <%# bool.Parse(Session[ "flag "].ToString())%> ' ImageUrl= "img/delete.gif " AlternateText= "删除 " CommandName= "delete ">
</asp:ImageButton>
<asp:ImageButton id=ibtnReply runat= "server " Visible= ' <%# bool.Parse(Session[ "flag "].ToString())%> ' ImageUrl= "img/reply.gif " AlternateText= "回复 " CommandName= "edit ">
</asp:ImageButton> <%# DataBinder.Eval(Container, "DataItem.M_CreateTime ", "{0:d} ") %> </TD>
</TR>
<TR>
<td bgcolor= "#FFFFFF "> </td>
<TD bgcolor= "#FFFFFF " colSpan= "2 "> <%# DataBinder.Eval(Container, "DataItem.M_Content ") %> <FONT face= "宋体 "> </FONT> <BR>
</TD>
</TR>
<TR>
<td width= "100px " bgcolor= "#FFFFFF "> 站长回复: </td>
<TD bgcolor= "#FFFFFF " colSpan= "2 ">
<%# DataBinder.Eval(Container, "DataItem.M_AdminReply ") %>
<FONT face= "宋体 "> </FONT>
</TD>
</TR>
<TR>
<TD bgcolor= "#FFFFFF " colSpan= "3 ">
</TD>
</TR>
</TABLE>
</ItemTemplate>
<EditItemTemplate>
<FONT face= "宋体 ">
<%# DataBinder.Eval(Container, "DataItem.M_Content ") %>
<BR>
<BR>
<asp:TextBox id= "txtReply " runat= "server " TextMode= "MultiLine " Columns= "20 " Rows= "2 "> </asp:TextBox> <BR>
<asp:Button id= "btnReply