title: Modal Pop up is not displaying update panel in asp.net
body: <p>This is my aspx page: </p>
  
  <pre><code>&lt;%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="TotalFee.aspx.cs" Inherits="TotalFee" %&gt;
  &lt;%@ Register assembly="Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" namespace="Microsoft.Reporting.WebForms" tagprefix="rsweb" %&gt;
  &lt;%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="asp" %&gt;
  &lt;asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server"&gt;
      &lt;script type="text/javascript"&gt;
  //        function ok(sender, e) {
  //            alert("Hello");
  //            __doPostBack('btnCreateBill','btnCreateBill_Click');
  //        }
  //        function cancel(sender, e) {
  //            $find('ModalPopupExtender1').hide();
  //        }
  //    
  
      &lt;/script&gt;
      &lt;style type="text/css"&gt;
          .style2
          {
              font-size: x-large;
              font-family: "Times New Roman", Times, serif;
          }
          .style3
          {
              color: #FF0000;
          }
         .panel 
  {
      position:static;
      top: 80%;
      left:50%;
       background-color:Aqua;
  
  
  }
  .modalBackground
      {
  
       z-index:auto;
      }
          &lt;/style&gt;
  
  &lt;/asp:Content&gt;
  &lt;asp:Content ID="Content2" runat="server" contentplaceholderid="MainContent"&gt;
      &lt;asp:ScriptManager ID="ScriptManager1" runat="server"&gt;&lt;/asp:ScriptManager&gt;
  
      &lt;table style="width:100%"&gt;
     &lt;tr&gt;
     &lt;td style="width:150px; vertical-align:top;" align="left" &gt;
         &lt;asp:Label ID="Classlabel" runat="server" Text="Class" CssClass="style2"&gt;&lt;/asp:Label&gt;
  
     &lt;/td&gt;
     &lt;td valign="top" align="center"&gt;
         &lt;asp:DropDownList ID="ClassDropDownList" runat="server" Width="150px" 
             DataSourceID="SqlDataSource1" DataTextField="ClassName" 
             DataValueField="ClassName" AutoPostBack="True" 
             onselectedindexchanged="ClassDropDownList_SelectedIndexChanged"&gt;
         &lt;/asp:DropDownList&gt;
  
         &lt;asp:SqlDataSource ID="SqlDataSource1" runat="server" 
             ConnectionString="&lt;%$ ConnectionStrings:dbbilling2.0ConnectionString4 %&gt;" 
             SelectCommand="SELECT [ClassName] FROM [tblClass]"&gt;&lt;/asp:SqlDataSource&gt;
  
         &lt;br /&gt;
  
     &lt;br /&gt;
     &lt;/td&gt;
  
     &lt;/tr&gt;
  
     &lt;tr&gt;
     &lt;td style="width:150px; vertical-align:top;" align="left" &gt;
         &lt;asp:Label ID="StudentNamelabel" runat="server" Text="StudentName" CssClass="style2"&gt;&lt;/asp:Label&gt;
  
     &lt;/td&gt;
     &lt;td valign="top" align="center"&gt;
         &lt;asp:DropDownList ID="StudentNameDropDownList" runat="server" Width="150px" 
             DataSourceID="SqlDataSource2" DataTextField="StudentName" 
             DataValueField="StudentID" AutoPostBack="True"&gt;
         &lt;/asp:DropDownList&gt;
         &lt;asp:SqlDataSource ID="SqlDataSource2" runat="server" 
             ConnectionString="&lt;%$ ConnectionStrings:dbbilling2.0ConnectionString3 %&gt;" 
  
             SelectCommand="SELECT [StudentID], [StudentName] FROM [tblStudentInfo] WHERE ([Class] = @Class)"&gt;
             &lt;SelectParameters&gt;
                 &lt;asp:ControlParameter ControlID="ClassDropDownList" Name="Class" 
                     PropertyName="SelectedValue" Type="String" /&gt;
             &lt;/SelectParameters&gt;
         &lt;/asp:SqlDataSource&gt;
         &lt;br /&gt;
     &lt;br /&gt;
     &lt;/td&gt;
     &lt;/tr&gt;
    &lt;tr&gt;
    &lt;td style="width:150px; vertical-align:top;" align="left" &gt;
         &lt;asp:Label ID="Monthlabel" runat="server" Text="Month" CssClass="style2"&gt;&lt;/asp:Label&gt;
         &lt;br /&gt;
         &lt;br /&gt;
         &lt;br /&gt;
         &lt;br /&gt;
         &lt;br /&gt;
  
  
     &lt;/td&gt;
  
    &lt;td valign="top" align="center"&gt;
         &amp;nbsp;&amp;nbsp;&amp;nbsp;
         &lt;asp:DropDownList ID="MonthDropDownList" runat="server" Width="150px" 
             DataSourceID="SqlDataSource3" DataTextField="Month" AutoPostBack="true"
             DataValueField="Month" OnDataBound="MonthDropDownListDataBound"
             onselectedindexchanged="MonthDropDownList_SelectedIndexChanged1"&gt;    
         &lt;/asp:DropDownList&gt;
  
         &lt;asp:SqlDataSource ID="SqlDataSource3" runat="server" 
             ConnectionString="&lt;%$ ConnectionStrings:dbbilling2.0ConnectionString2 %&gt;" 
             SelectCommand="SELECT [Month] FROM [tblMonth]"&gt;&lt;/asp:SqlDataSource&gt;
         &lt;br /&gt;
    &lt;br /&gt;
      &lt;/td&gt;
      &lt;/tr&gt;
      &lt;tr&gt;
     &lt;td style="width:150px; vertical-align:top;" align="left" &gt;
         &lt;asp:Label ID="MonthlyFeelabel" runat="server" Text="Monthly Fee" CssClass="style2"&gt;&lt;/asp:Label&gt;
     &lt;/td&gt;
     &lt;td valign="top" align="center"&gt;
         &amp;nbsp;&amp;nbsp;
         &lt;asp:TextBox ID="txtMonthlyFee" runat="server" Width="150px"&gt;&lt;/asp:TextBox&gt;
         &lt;asp:RequiredFieldValidator ID="MonthlyFeeValidator" runat="server" 
             ControlToValidate="txtMonthlyFee" CssClass="style3"&gt;*&lt;/asp:RequiredFieldValidator&gt;
         &lt;br /&gt;
         &lt;br /&gt;
     &lt;br /&gt;
     &lt;/td&gt;
      &lt;/tr&gt;
     &lt;tr&gt;
     &lt;td style="width:150px; vertical-align:top;" align="left" &gt;
         &lt;asp:Label ID="TransportFeelabel" runat="server" Text="Transport Fee" CssClass="style2"&gt;&lt;/asp:Label&gt;
     &lt;/td&gt;
     &lt;td valign="top" align="center"&gt;
         &amp;nbsp;&amp;nbsp;
         &lt;asp:TextBox ID="txtTransportFee" runat="server" Width="150px"&gt;&lt;/asp:TextBox&gt;
         &lt;asp:RequiredFieldValidator ID="TransportationFeeValidator" runat="server" 
             ControlToValidate="txtTransportFee" CssClass="style3"&gt;*&lt;/asp:RequiredFieldValidator&gt;
         &lt;br /&gt;
         &lt;br /&gt;
     &lt;br /&gt;
     &lt;/td&gt;
      &lt;/tr&gt;
       &lt;tr&gt;
     &lt;td style="width:150px; vertical-align:top;" align="left" &gt;
         &lt;asp:Label ID="Hostelfeelabel" runat="server" Text="Hostel Fee" CssClass="style2"&gt;&lt;/asp:Label&gt;
     &lt;/td&gt;
     &lt;td valign="top" align="center"&gt;
         &amp;nbsp;
         &lt;asp:TextBox ID="txtHostelFee" runat="server" Width="150px"&gt;&lt;/asp:TextBox&gt;
         &lt;asp:RequiredFieldValidator ID="HostelFeeValidator" runat="server" 
             ControlToValidate="txtHostelFee" CssClass="style3"&gt;*&lt;/asp:RequiredFieldValidator&gt;
         &lt;br /&gt;
         &lt;br /&gt;
     &lt;br /&gt;
     &lt;/td&gt;
      &lt;/tr&gt;
        &lt;tr&gt;
     &lt;td style="width:150px; vertical-align:top;" align="left" &gt;
         &lt;asp:Label ID="ECAFeeLabel" runat="server" Text="ECA Fee" CssClass="style2"&gt;&lt;/asp:Label&gt;
     &lt;/td&gt;
     &lt;td valign="top" align="center"&gt;
         &amp;nbsp;
         &lt;asp:TextBox ID="txtECAFee" runat="server" Width="150px"&gt;&lt;/asp:TextBox&gt;
         &lt;asp:RequiredFieldValidator ID="ECAFeeValidator" runat="server" 
             ControlToValidate="txtECAFee" CssClass="style3"&gt;*&lt;/asp:RequiredFieldValidator&gt;
         &lt;br /&gt;
         &lt;br /&gt;
     &lt;br /&gt;
     &lt;/td&gt;
      &lt;/tr&gt;
        &lt;tr&gt;
     &lt;td style="width:300px; vertical-align:top;" align="left" &gt;
         &lt;asp:Label ID="DueFromPreviousMonthLabel" runat="server" 
             Text="Due From Previous Month" CssClass="style2"&gt;&lt;/asp:Label&gt;
          &lt;br /&gt;
          &lt;/td&gt;
     &lt;td valign="top" align="center"&gt;
        &lt;asp:TextBox ID="txtDueFromPreviousMonth" runat="server" Width="150px" Text="0"&gt;&lt;/asp:TextBox&gt;
         &lt;asp:RequiredFieldValidator ID="DueFromPreviousMonthValidator" runat="server" 
             ControlToValidate="txtECAFee" CssClass="style3"&gt;*&lt;/asp:RequiredFieldValidator&gt;
         &lt;br /&gt;
         &lt;br /&gt;
     &lt;br /&gt;
        &lt;/td&gt;
      &lt;/tr&gt;
       &lt;tr&gt;
     &lt;td style="width:150px; vertical-align:top;" align="left" &gt;
         &lt;asp:Label ID="TotalFeeLabel" runat="server" Text="Total Fee" CssClass="style2"&gt;&lt;/asp:Label&gt;
     &lt;/td&gt;
     &lt;td valign="top" align="center"&gt;
         &lt;asp:TextBox ID="txtTotalFee" runat="server" Width="150px" ReadOnly="true"&gt;&lt;/asp:TextBox&gt;
         &lt;br /&gt;
         &lt;br /&gt;
     &lt;br /&gt;
     &lt;/td&gt;
      &lt;/tr&gt;
       &lt;tr&gt;
       &lt;td style="width:150px; vertical-align:top;" align="left" &gt;
         &lt;asp:Label ID="PaidLabel" runat="server" Text="Paid" CssClass="style2"&gt;&lt;/asp:Label&gt;
     &lt;/td&gt;
     &lt;td valign="top" align="center"&gt;
         &lt;asp:CheckBox ID="ChkPaidLabel" runat="server" /&gt;
         &lt;br /&gt;
         &lt;br /&gt;
     &lt;br /&gt;
     &lt;/td&gt;
     &lt;/tr&gt;
       &lt;tr&gt;
     &lt;td style="width:150px; vertical-align:top;" align="left" &gt;
  
        &lt;/td&gt;
     &lt;td valign="top" align="right"&gt;
         &lt;asp:Button ID="btnSubmit" runat="server" Text="Submit" Width="150px"
             onclick="btnSubmit_Click" /&gt;
         &lt;asp:Button ID="btnReset" runat="server" Text="Reset" Width="150px" /&gt;
         &lt;asp:Button ID="btnCreateBill" runat="server" Text="CreateBill" Width="150px"
           OnClick="btnCreateBill_Click"/&gt;
  
  
         &lt;%--&lt;asp:PopupControlExtender ID="btnCreateBill_PopupControlExtender" OffsetX="-1100" OffsetY="115" 
             runat="server" DynamicServicePath="" Enabled="True" ExtenderControlID=""  
             TargetControlID="btnCreateBill"  PopupControlID="UpdatePanel1"&gt;
         &lt;/asp:PopupControlExtender&gt;--%&gt;
  
  
     &lt;/td&gt;
      &lt;/tr&gt;
       &lt;tr&gt;
     &lt;td style="width:150px; vertical-align:top;" align="left" colspan="2" &gt; 
     &lt;asp:UpdatePanel ID="UpdatePanel1" runat="server"&gt;   
   &lt;ContentTemplate&gt;    
   &lt;asp:ModalPopupExtender ID="ModalPopUpExtender1" runat="server" PopupControlID="UpdatePanel1"
      TargetControlID="UpdatePanel1" DropShadow="false" BackgroundCssClass="modalBackground"&gt;&lt;/asp:ModalPopupExtender&gt;   
   &lt;rsweb:ReportViewer ID="ReportingForPrintingReportViewer" runat="server" Visible="false" CssClass="panel"
     Width="100%" Height="100%" Font-Names="Verdana" Font-Size="8pt"
     InteractiveDeviceInfos="(Collection)" WaitMessageFont-Names="Verdana"
     WaitMessageFont-Size="14pt"&gt;  
     &lt;LocalReport ReportPath="Report.rdlc"&gt;
     &lt;DataSources&gt;
     &lt;rsweb:ReportDataSource DataSourceId="ObjectDataSource2" Name="DataSet1" /&gt;
     &lt;/DataSources&gt;
     &lt;/LocalReport&gt;
     &lt;/rsweb:ReportViewer&gt;  
     &lt;asp:ObjectDataSource ID="ObjectDataSource2" runat="server" 
       SelectMethod="GetData" TypeName="DataSet1TableAdapters.tblTotalFeeTableAdapter"&gt;
     &lt;/asp:ObjectDataSource&gt;
     &lt;/ContentTemplate&gt;
          &lt;/asp:UpdatePanel&gt;
  
           &lt;/td&gt;
  
      &lt;/tr&gt;
       &lt;/table&gt;
          &lt;/asp:Content&gt;
  </code></pre>
  
  <p>and this is my cs page:</p>
  
  <pre><code>protected void btnCreateBill_Click(object sender, EventArgs e)
      {
          ModalPopUpExtender1.Show();
          DisplayReport();
  
      }
  </code></pre>
  
  <p>Why isn't <strong>UpdatePanel1</strong> being displayed when we click <strong>btnCreateBill</strong>?? I want to show <strong>UpdatePanel1</strong> as popup when i click <strong>btnCreateBill</strong>
  When I placed <code>modal pop up extender</code> inside my <code>updatepanel1</code> it gave the error
  An extender can't be in a different UpdatePanel than the control it extends.</p>