Dropdown Autopostback属性为true并更新面板问题 [英] Dropdown Autopostback property true and update panel problem

查看:122
本文介绍了Dropdown Autopostback属性为true并更新面板问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在asp.net中使用更新面板。在更新面板中有一个下拉列表,其中自动回发属性为true。当我滚动长页面并选择下拉项目时,页面将转到页面顶部。但我必须将该页面显示为已存在。请帮助我。

I use update panel in asp.net. In the update panel there is a dropdownlist which auto postback property is true. when I scroll the long page and select the dropdown item then the page go to the top of the page. But I have to show the page as existing. please help me.

推荐答案

问题是,当您在下拉列表中选择项目时,它将回发整个页面。

设置 AsyncPostBackTrigger 如下

the problem is when you select item on dropdownlist it will post back entire page.
set AsyncPostBackTrigger as below
<Triggers> 
<asp:AsyncPostBackTrigger ControlID="DropDownList1" EventName="SelectedIndexChanged" /> 
</Triggers> 
</asp:UpdatePanel> 


这篇关于Dropdown Autopostback属性为true并更新面板问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆