Nirmal KumarC

Nirmal KumarC

  • 1.1k
  • 327
  • 75.9k

How to solve the Trigger Event not fired button

Apr 20 2015 5:50 AM

How to fired rthe button in update panel
I am below already using trigger but not fired  yes button how to solve this problem 
<asp:UpdatePanel ID="UpdatePanel2" runat="server" UpdateMode="Always" ChildrenAsTriggers="true">
<ContentTemplate>
<asp:Panel ID="pn2" runat="server" Visible = "true" BackColor = "Bisque" Width = "770px">
<table id="tblPopup" runat="server">
<tr>

<td>
<asp:Label ID="lblEmployeeREjected" runat="server" Text="are u sure want to delete current employee. Press Yes to Delete and No to cancel"
Font-Bold="True" ForeColor="#3E3EFF" Width="770px" BackColor="White" Visible="false" ></asp:Label>

</td>
</tr>
<tr>
<td align = "center">
<asp:Button ID="btnYes" runat="server" OnClick="btnYes_Click" Text="Yes" CausesValidation="false"
Width="50px" />
<asp:Button ID="btnNo" runat="server" OnClick="btnNo_Click" Text="No" CausesValidation="false"
Width="50px" />
</td>
</tr>
</table>
</asp:Panel>
<asp:ModalPopupExtender ID="MPE" runat="server" PopupControlID="pn2" TargetControlID="tblPopup" PopupDragHandleControlID="header" BehaviorID="btnYes"
BackgroundCssClass="Bg">
</asp:ModalPopupExtender>
</ContentTemplate>
<Triggers>
<asp:PostBackTrigger ControlID="btnYes" />
<%--<asp:PostBackTrigger ControlID="btnYes" />
<asp:PostBackTrigger ControlID="btnNo" />--%>
<%--<asp:AsyncPostBackTrigger ControlID="btnYes" />
--%> </Triggers>
</asp:UpdatePanel>

Answers (3)