title: Calendar extender in modal popup extender ASP.NET not working
body: <p>I'm using a calendar extender in a panel which popup using modalpopup extender, so panel is poped up contains the calendar extender but the calendar is behind every thing, i tried to change the z-index but all in vain, seems to me that it is a bug in the ASP.net AjaxToolKit.Any one has an idea about this problem and if it can be solved?</p>
  
  <p>Edit:</p>
  
  <pre><code>&lt;style type="text/css"&gt;
      .modalBackground
      {
          background-color: Gray;
          filter: alpha(opacity=70);
          opacity: 0.2;
      }
      .ob_show_panelsholder
      {
          border: 1px solid #736F6E;
      }
      .enterzipCalenderCompliant {
      PADDING-RIGHT: 10px;  FLOAT: left /*No display=inline*/
      }
      .ajax__calendar_container { z-index : 1000 ; }
  
  &lt;/style&gt;
  &lt;script type="text/javascript"&gt;
      function calendarShown(sender, args) {
          sender.style.zIndex = 10005;
      }
  &lt;/script&gt;
  &lt;asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional"&gt;
      &lt;ContentTemplate&gt;
          &lt;asp:Panel ID="_pnlShowPersonalData" runat="server"&gt;
              &lt;table class="style1"&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Image ID="_imgCurrentPP" runat="server" Height="100px" Width="100px" /&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="Label3" runat="server" Text="First name :"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="_lblFirstName" runat="server"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="Label5" runat="server" Text="Last name :"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="_lblLastName" runat="server"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="Label7" runat="server" Text="BirthDate :"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="_lblBirthDate" runat="server"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="Label10" runat="server" Text="Mobile number :"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="_lblMobileNumber" runat="server"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="Label12" runat="server" Text="Location :"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="_lblLocation" runat="server"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="Label13" runat="server" Text="Gender :"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="_lblGender" runat="server"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Button ID="_btnEditPersonalData" runat="server" Text="Edit Profile" /&gt;
                          &lt;asp:ModalPopupExtender ID="_btnEditPersonalData_ModalPopupExtender" runat="server"
                              DynamicServicePath="" Enabled="True" TargetControlID="_btnEditPersonalData" BackgroundCssClass="modalBackground"
                              PopupControlID="_pnlEditPersonalData" CancelControlID="_btnCancel"&gt;
                          &lt;/asp:ModalPopupExtender&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
              &lt;/table&gt;
          &lt;/asp:Panel&gt;
          &lt;asp:Panel ID="_pnlEditPersonalData" runat="server"&gt;
              &lt;table&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="_FirstName" runat="server" Text="First name :" &gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                      &lt;td&gt;
                          &lt;asp:TextBox ID="_txtFirstName" runat="server"&gt;&lt;/asp:TextBox&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="_LastName" runat="server" Text="Last name :"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                      &lt;td&gt;
                          &lt;asp:TextBox ID="_txtLastName" runat="server"&gt;&lt;/asp:TextBox&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="_BirthDate" runat="server" Text="Birth date :"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                      &lt;td class="ajax__calendar_container"&gt;
                          &lt;asp:TextBox ID="_txtBirthDate" runat="server"&gt;&lt;/asp:TextBox&gt;
                          &lt;asp:MaskedEditExtender ID="_txtBirthDate_MaskedEditExtender" runat="server" Enabled="True"
                              TargetControlID="_txtBirthDate" MaskType="Date" ErrorTooltipEnabled="True" MessageValidatorTip="true"
                              Mask="99/99/9999"&gt;
                          &lt;/asp:MaskedEditExtender&gt;
                          &lt;div&gt;
                          &lt;asp:CalendarExtender ID="_txtBirthDate_CalendarExtender" runat="server" Enabled="True"
                              PopupButtonID="_btnCalendar" TargetControlID="_txtBirthDate"&gt;
                          &lt;/asp:CalendarExtender&gt;
                          &lt;/div&gt;
                          &lt;asp:ImageButton ID="_btnCalendar" runat="server" ImageUrl="~/Images/calendar_button_b.jpg" /&gt;
  &lt;%--                                            &lt;img alt="Icon" src="~/Images/calendar_button_b.jpg" id="Image1" /&gt;--%&gt;
  
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="_ProfilePic" runat="server" Text="Profile picture :"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                      &lt;td&gt;
                          &lt;asp:FileUpload ID="FileUpload1" runat="server" /&gt;
                          &lt;asp:Label ID="Label1" runat="server"&gt;&lt;/asp:Label&gt;
                          &lt;%--                    &lt;asp:RequiredFieldValidator ID="RequiredFieldValidator8" runat="server" ControlToValidate="FileUpload1"--%&gt;&lt;%--                        ErrorMessage="*" ValidationGroup="signup"&gt;&lt;/asp:RequiredFieldValidator&gt;--%&gt;
                          &lt;asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ValidationExpression="^(([a-zA-Z]:)|(\\{2}\w+)\$?)(\\(\w[\w].*))(.png|.jpg)$"
                              ControlToValidate="FileUpload1" ErrorMessage="Please Select Png or Jpg File"
                              ValidationGroup="UploadFile"&gt;&lt;/asp:RegularExpressionValidator&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="_MobileNumber" runat="server" Text="Mobile number :"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                      &lt;td&gt;
                          &lt;asp:TextBox ID="_txtMobileNumber" runat="server"&gt;&lt;/asp:TextBox&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="_Password" runat="server" Text="Password :"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                      &lt;td&gt;
                          &lt;asp:TextBox ID="_txtPassword" runat="server"&gt;&lt;/asp:TextBox&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
              &lt;/table&gt;
              &lt;asp:UpdatePanel ID="UpdatePanel2" runat="server" UpdateMode="Conditional"&gt;
                  &lt;ContentTemplate&gt;
                      &lt;asp:Panel ID="_pnlLocation" runat="server"&gt;
                          &lt;table width="21%"&gt;
                              &lt;tr&gt;
                                  &lt;td&gt;
                                      &lt;asp:Label ID="_Country" runat="server" Text="Country :"&gt;&lt;/asp:Label&gt;
                                  &lt;/td&gt;
                                  &lt;td&gt;
                                      &lt;uc1:CountryListUC ID="CountryListUC1" runat="server" EnablePostBack="True" EnableValidation="False"
                                          OnListIndexChanged="CountrySelectedIndexChanged" /&gt;
                                  &lt;/td&gt;
                              &lt;/tr&gt;
                              &lt;tr&gt;
                                  &lt;td&gt;
                                      &lt;asp:Label ID="_Governet" runat="server" Text="Governet:"&gt;&lt;/asp:Label&gt;
                                  &lt;/td&gt;
                                  &lt;td&gt;
                                      &lt;uc2:GovernateListUC ID="GovernateListUC1" runat="server" OnListIndexChanged="GovernateSelectedIndexChanged"
                                          Enabled="False" EnablePostBack="True" EnableValidation="False" /&gt;
                                  &lt;/td&gt;
                              &lt;/tr&gt;
                              &lt;tr&gt;
                                  &lt;td&gt;
                                      &lt;asp:Label ID="_District" runat="server" Text="District :"&gt;&lt;/asp:Label&gt;
                                  &lt;/td&gt;
                                  &lt;td&gt;
                                      &lt;uc3:DistrictListUC ID="DistrictListUC1" runat="server" Enabled="False" EnablePostBack="True"
                                          EnableValidation="False" /&gt;
                                  &lt;/td&gt;
                              &lt;/tr&gt;
                          &lt;/table&gt;
                      &lt;/asp:Panel&gt;
                  &lt;/ContentTemplate&gt;
                  &lt;Triggers&gt;
                      &lt;asp:AsyncPostBackTrigger ControlID="CountryListUC1" EventName="ListIndexChanged" /&gt;
                  &lt;/Triggers&gt;
              &lt;/asp:UpdatePanel&gt;
              &lt;table width="22%"&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Label ID="_Gender" runat="server" Text="Gender :"&gt;&lt;/asp:Label&gt;
                      &lt;/td&gt;
                      &lt;td&gt;
                          &lt;asp:DropDownList ID="_ddlGender" runat="server"&gt;
                              &lt;asp:ListItem Value="1"&gt;Male&lt;/asp:ListItem&gt;
                              &lt;asp:ListItem Value="2"&gt;Female&lt;/asp:ListItem&gt;
                          &lt;/asp:DropDownList&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;
                          &lt;asp:Button ID="_btnSaveChanges" runat="server" OnClick="_btnSaveChages_Click" Text="Save changes"
                              ValidationGroup="signup" /&gt;
                      &lt;/td&gt;
                      &lt;td valign="bottom"&gt;
                          &lt;asp:Button ID="_btnCancel" runat="server" Text="Cancel" /&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
              &lt;/table&gt;
          &lt;/asp:Panel&gt;
      &lt;/ContentTemplate&gt;
  &lt;/asp:UpdatePanel&gt;
  </code></pre>