Quantcast
Channel: ASP.NET AJAX + Ajax Control Toolkit (ACT)
Viewing all articles
Browse latest Browse all 5678

Custom event raised from usercontrol inside update panel cause full postback

$
0
0

Hi,

I faced this issue while trying to implement a multiselect cascading dropdown feature using poupextender and a textbox. I have written usercontrol with a poupextender whose popup control id is set to panel which contains listview. Once the user selects items inside listviw he needs to click on the Ok button in the user control. On ok button click the selcted values will be written to textbox which is also inside user control. I have also exposed a method to set datasource of the lsitview from parent page to make it cascading. When the user clicks Ok button inside the usercontrol a custom event will be raised so that the user can refresh the data in other usercontrols and thus it will act as cascading dropdown.

now I have placed the user cotnrols as shown here,

<tr><td>Country</td><td><uc1:multiSelectDropdown runat="server" ID="msddlCountry" DropdownWidth="150" /></td><td>State</td><td><asp:UpdatePanel runat="server" ID="UpdatePanel1" UpdateMode="Conditional"><ContentTemplate><uc1:multiSelectDropdown runat="server" ID="msddlState" DropdownWidth="150" /></ContentTemplate><Triggers><asp:AsyncPostBackTrigger ControlID="msddlCountry" EventName="MultiSelectionChanged" /></Triggers></asp:UpdatePanel></td><td>Project</td><td><asp:UpdatePanel runat="server" ID="UpdatePanel2" UpdateMode="Conditional"><ContentTemplate><uc1:multiSelectDropdown runat="server" ID="msddlcity" DropdownWidth="150" /></ContentTemplate><Triggers><asp:AsyncPostBackTrigger ControlID="msddlState" EventName="MultiSelectionChanged" /></Triggers></asp:UpdatePanel></td></tr>

But seems like it is not working as the custom event is causing full post back and the data in the texboxes are reset.

How to enable partial rendering in this scenario?

 


Viewing all articles
Browse latest Browse all 5678

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>