asp:UpdatePanel 中为什么不能实现局部刷新
<asp:ScriptManagerID="ScriptManager1"runat="server"EnablePartialRendering="true"></as...
<asp:ScriptManager ID="ScriptManager1" runat="server" EnablePartialRendering="true">
</asp:ScriptManager>
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<ContentTemplate>
<asp:Repeater ID="Repeater1" runat="server">
<ItemTemplate>
<tr>
<td align="center" bgcolor="#FFFFFF">
<asp:CheckBox ID="chkSelect" runat="server" /> </td>
<td align="left" bgcolor="#FFFFFF" class="pl10"><a href="#"><%# Eval("title")%></a></td>
<td align="left" bgcolor="#FFFFFF" class="pl10"><%# Eval("job") %></td>
<td align="center" bgcolor="#FFFFFF" class="green"><%# GetState(Convert.ToInt32(Eval("term")), Convert.ToDateTime(Eval("recruitmentTime")))%></td>
<td align="center" bgcolor="#FFFFFF"><%# Eval("recruitmentTime").ToString()%></td>
<td align="center" bgcolor="#FFFFFF"><a href='Recruitment.aspx?recruitmentId=<%# Eval("recruitmentId").ToString() %>'>查看/修改</a> | <a href="#">删除</a></td>
</tr>
</ItemTemplate>
</asp:Repeater>
<tr>
<td align="center" bgcolor="#FFFFFF">
<asp:CheckBox ID="chkCheckAll" runat="server" AutoPostBack="true"
oncheckedchanged="chkCheckAll_CheckedChanged" /> 全选
</td>
<td height="35" colspan="5" align="left" valign="middle" bgcolor="#FFFFFF" class="pl10"><input name="" type="image" src="images/btn5.gif" />
<span class="pl10"><input name="" type="image" src="images/btn7.gif" />
</span>
</td>
</tr>
<tr>
<td height="35" colspan="6" align="center" bgcolor="#FFFFFF">
<div class="page">
<Pager:AspNetPager ID="AspNetPager1" runat="server" FirstPageText="首页"
LastPageText="尾页" NextPageText="下一页" PrevPageText="上一页" PageSize="10"
onpagechanging="AspNetPager1_PageChanging" UrlPaging="True">
</Pager:AspNetPager>
</div> </td>
</tr>
</ContentTemplate>
</asp:UpdatePanel>
我点分页后页面还是刷新了。。点那个全选也是的。。这是为什么呢?
我是不是少写了什么属性或是什么东西啊? 这个控件到底应该怎么用哦? 展开
</asp:ScriptManager>
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<ContentTemplate>
<asp:Repeater ID="Repeater1" runat="server">
<ItemTemplate>
<tr>
<td align="center" bgcolor="#FFFFFF">
<asp:CheckBox ID="chkSelect" runat="server" /> </td>
<td align="left" bgcolor="#FFFFFF" class="pl10"><a href="#"><%# Eval("title")%></a></td>
<td align="left" bgcolor="#FFFFFF" class="pl10"><%# Eval("job") %></td>
<td align="center" bgcolor="#FFFFFF" class="green"><%# GetState(Convert.ToInt32(Eval("term")), Convert.ToDateTime(Eval("recruitmentTime")))%></td>
<td align="center" bgcolor="#FFFFFF"><%# Eval("recruitmentTime").ToString()%></td>
<td align="center" bgcolor="#FFFFFF"><a href='Recruitment.aspx?recruitmentId=<%# Eval("recruitmentId").ToString() %>'>查看/修改</a> | <a href="#">删除</a></td>
</tr>
</ItemTemplate>
</asp:Repeater>
<tr>
<td align="center" bgcolor="#FFFFFF">
<asp:CheckBox ID="chkCheckAll" runat="server" AutoPostBack="true"
oncheckedchanged="chkCheckAll_CheckedChanged" /> 全选
</td>
<td height="35" colspan="5" align="left" valign="middle" bgcolor="#FFFFFF" class="pl10"><input name="" type="image" src="images/btn5.gif" />
<span class="pl10"><input name="" type="image" src="images/btn7.gif" />
</span>
</td>
</tr>
<tr>
<td height="35" colspan="6" align="center" bgcolor="#FFFFFF">
<div class="page">
<Pager:AspNetPager ID="AspNetPager1" runat="server" FirstPageText="首页"
LastPageText="尾页" NextPageText="下一页" PrevPageText="上一页" PageSize="10"
onpagechanging="AspNetPager1_PageChanging" UrlPaging="True">
</Pager:AspNetPager>
</div> </td>
</tr>
</ContentTemplate>
</asp:UpdatePanel>
我点分页后页面还是刷新了。。点那个全选也是的。。这是为什么呢?
我是不是少写了什么属性或是什么东西啊? 这个控件到底应该怎么用哦? 展开
展开全部
</ContentTemplate>下面加
ControlID 控件名 EventName 事件名
<Triggers>
<asp:AsyncPostBackTrigger ControlID="gvProduct" EventName="RowCommand" />
<asp:AsyncPostBackTrigger ControlID="btnSearch" EventName="Click" />
<asp:AsyncPostBackTrigger ControlID="gvProduct" EventName="PageIndexChanging" />
</Triggers>
ControlID 控件名 EventName 事件名
<Triggers>
<asp:AsyncPostBackTrigger ControlID="gvProduct" EventName="RowCommand" />
<asp:AsyncPostBackTrigger ControlID="btnSearch" EventName="Click" />
<asp:AsyncPostBackTrigger ControlID="gvProduct" EventName="PageIndexChanging" />
</Triggers>
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询