开发者

AJAX UpdatePanel Causes Entire Page Postback

开发者 https://www.devze.com 2023-03-06 17:39 出处:网络
I am facing a problem that I cannot solve! I have two DropDownLists inside an Updat开发者_Go百科ePanel with AutoPostBack=true, UpdateMode=\"always\", ChildrenAsTriggers=\"true\" and EnableViewState=\

I am facing a problem that I cannot solve!

I have two DropDownLists inside an Updat开发者_Go百科ePanel with AutoPostBack=true, UpdateMode="always", ChildrenAsTriggers="true" and EnableViewState="false".

The values shown inside the second DropDownList are dependent of the SelectedValue on the first one.

Whenever the selected value on a DropDownList, the entire page is postback. I want only the postback running inside the updatepanel.

Note: The ScriptManager has EnablePartialRendering="true".

What should I do?


Well you must have wrapped the whole page inside the Update Panel i suppose and also as i suspect UpdateMode="always" is the cukprit. Change that to Conditional. Because the update panel is going to be refreshed only on children triggers and not when anyhting and everything happens on the page.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号