title: Prevent closing of ModalPopup on postback
body: <p>I'm using the ModalPopupExtender control from the AJAX toolkit. This control extends a panel which contains a CreateUserWizard control. However, the validation of the CreateUserWizard control causes a postback to the server, which closes the popup. I'd like the popup to remain open, even after the postback. From what I can gather, I should be using an UpdatePanel. However, I can't seem to get it working. The reason it's being quite tricky is because the structure <em>should</em> be :</p>
  
  <pre><code>ModalPopupExtender
  &lt;Panel&gt;
  &lt;UpdatePanel&gt;
  &lt;ContentTemplate&gt;...&lt;/ContentTemplate&gt;
  &lt;/UpdatePanel&gt;
  &lt;/Panel&gt;
  </code></pre>
  
  <p>I can't follow this structure because the <code>ModalPopupExtender</code> relies on a button which is contained within the CreateUserWizard control. Therefore, it has to be added within the <code>&lt;asp:CreateUserWizard&gt; &lt;/asp:CreateUserWizard&gt;</code> tags. I would like the submit button, built into the CreateUserWizard control, to force an update of the panel. Any suggestions on how the structure should  be? My code is highly customised, so it's quite long. However, the key structure is similar to this:</p>
  
  <pre><code>&lt;asp:Panel&gt;
    &lt;asp:CreateUserWizard&gt;
      &lt;WizardSteps&gt;
         &lt;asp:CreateUserWizardStep&gt;
            &lt;ContentTemplate&gt;
  
            //Form Controls here
            &lt;/ContentTemplate&gt;
            &lt;CustomNavigationTemplate&gt;
                 //The SUBMIT button that should force update
                 //CANCEL button
               &lt;asp:ModalPopupExtender /&gt; //References the CANCEL button therefore has to be here
            &lt;/CustomNavigationTemplate&gt;
  
         &lt;/asp:CreateUserWizardStep&gt;
      &lt;/WizardSteps&gt;
  &lt;/asp:CreateUserWizard&gt;
  
  &lt;/asp:Panel&gt;
  </code></pre>
  
  <p>Whereabouts would the UpdatePanel be placed? Or is there a more efficient way of ensuring the ModalPopup doesn't close?</p>
  
  <p>Thanks for any help</p>