I have a GridView
(ucLAD) in my UpdatePanel
(upnlListing). Inside my ucLAD
I have a checkbox and an action for rowClicked
:
<asp:UpdatePanel ID="upnlListing" runat="server" >
<Triggers>
<asp:AsyncPostBackTrigger ControlID="ucLAD"/>
<%-- <asp:PostBackTrigger ControlID="ucLAD"/> --%>
</Triggers>
<ContentTemplate>
<asp:Panel ID="pnlRequest" runat="server" style="margin-top:15px; height: auto;">
<ucgv:BaseGrid runat="server" ID="ucLAD"/>
</asp:Panel>
</ContentTemplate>
</asp:UpdatePanel>
When I use the PostBackTrigger
the action performed would be the rowClicked
same thing happen when I check the checkbox but when I use the AsyncPostBackTrigger
, I can check the checkboxes but when I click the row, the action for rowClicked
don't trigger. How can I fix this?
As describe in on of the SO question
What is the difference between AsyncPostBackTrigger & PostBackTrigger?
Controls inside an UpdatePanel by default cause a partial page update, controls outside cause a postback, using these triggers it is possible to change this behaviour as required.
From http://seminaarit.codezone.fi/video/devdays-2007/track1/2/2-ASP-dotNET_AJAX_Extensions.ppt
Converts postbacks into async callbacks Typically used to trigger updates when controls outside an UpdatePanel post back If ChildrenAsTriggers="false", can be used to specify which controls inside UpdatePanel should call back rather than post back
Lets controls inside UpdatePanel post back Typically used to allow certain controls to post back when ChildrenAsTriggers="true
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With