当前位置: 代码迷 >> ASP.NET >> AJAX无刷新翻页 用ScriptManager可以实现么解决思路
  详细解决方案

AJAX无刷新翻页 用ScriptManager可以实现么解决思路

热度:6652   发布时间:2013-02-25 00:00:00.0
AJAX无刷新翻页 用ScriptManager可以实现么
<asp:ScriptManager ID="ScriptManager1" runat="server" /></asp:ScriptManager>  
  <asp:UpdatePanel ID="UpdatePanel1" runat="server">  
  <contenttemplate>  
  <asp:GridView ID="GridView1" runat="server" Width="538px" AutoGenerateColumns="False"
  AllowPaging="true" OnSorting="GridView1_sort" OnPageIndexChanging="myPageChanging"
  AllowSorting="true" OnRowDataBound="GridView1_RowDataBound" BorderColor="White"
  PageSize="5" >
  <PagerStyle BackColor="#EEEFEE" Font-Size="Small" />
   
  <PagerSettings FirstPageText="第一页" LastPageText="最后" NextPageText="下一页" Position="Top" PreviousPageText="上一页" Mode="NextPreviousFirstLast" />
  </contenttemplate>  
  </asp:UpdatePanel>
为什么上面的代码不可以实现。
 

------解决方案--------------------------------------------------------
可以 但是代价很大
------解决方案--------------------------------------------------------
可以的。
绑定,翻页代码是否正确?
------解决方案--------------------------------------------------------
<contenttemplate> 换成大写 <ContentTemplate>
格式一定正确。
HTML code
<asp:ScriptManager ID="ScriptManager1" runat="server">    </asp:ScriptManager>    <asp:UpdatePanel ID="UpdatePanel1" runat="server">            <ContentTemplate>        </ContentTemplate>    </asp:UpdatePanel>
  相关解决方案