Bug - PopupControlExtender and Wizards

Last post 02-21-2007 1:08 PM by jmaag. 6 replies.

Sort Posts:

  • Bug - PopupControlExtender and Wizards

    10-31-2006, 4:34 PM
    • Member
      622 point Member
    • Matt M
    • Member since 08-25-2006, 5:25 PM
    • Eastern WA, USA
    • Posts 128

    The page will render space for the control that is to be popped up if the current step doesn't have the popupcontrolextender (PCE). The step with the PCE  correctly renders. Sample code:

     

     

    <%@ Page Language="VB" AutoEventWireup="true" CodeFile="Default.aspx.vb" Inherits="_Default" %>
    <%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="act" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">

    <html xmlns="http://www.w3.org/1999/xhtml">
    <head runat="server">
    <title>Untitled Page</title>
    </head>
    <body>
    <form id="form1" runat="server">
    <ajax:ScriptManager runat="server" ID="sm1" EnablePartialRendering="true"></ajax:ScriptManager>
    <asp:Calendar ID="Cal1" runat="server" style="visibility: hidden; " />
    <asp:Wizard ID="NewFormWizard" runat="server" Width="100%" BackColor="#EFF3FB" BorderColor="#B5C7DE" BorderWidth="1px" Font-Names="Verdana" Font-Size="0.8em" CancelButtonText="Cancel" DisplayCancelButton="true" DisplaySideBar="false" Height="70%" >
    <WizardSteps>
    <asp:WizardStep ID="WizardStepGeneral" runat="server" Title="*General">
    Hi.
    </asp:WizardStep>
    <asp:WizardStep ID="WizardStepStyle" runat="server" Title="*Style">
    Hello again.
    <asp:TextBox runat="server" ID="blah" />
    <act:PopupControlExtender runat="server" ID="blahpce" PopupControlID="Cal1"
    TargetControlID="blah" />
    </asp:WizardStep>
    </WizardSteps>
    </asp:Wizard>
    </form>
    </body>
    </html>

      

    Note the extra space at the top of step 1.  When you move to step 2, where the popupcontrolextender is, there's no space, as the expected behavior dictates. 

     

    No wizard, no problem:

     
    <%@ Page Language="VB" AutoEventWireup="true" CodeFile="Default.aspx.vb" Inherits="_Default" %>
    <%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="act" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">

    <html xmlns="http://www.w3.org/1999/xhtml">
    <head runat="server">
    <title>Untitled Page</title>
    </head>
    <body>
    <form id="form1" runat="server">
    <ajax:ScriptManager runat="server" ID="sm1" EnablePartialRendering="true"></ajax:ScriptManager>
    <asp:Calendar ID="Cal1" runat="server" style="visibility: hidden; " />
    <asp:TextBox runat="server" ID="blah" />
    <act:PopupControlExtender runat="server" ID="blahpce" PopupControlID="Cal1"
    TargetControlID="blah" />
    </form>
    </body>
    </html>
     
      
  • Re: Bug - PopupControlExtender and Wizards

    11-13-2006, 6:04 PM
    • Star
      8,710 point Star
    • David Anson
    • Member since 04-11-2006, 1:39 AM
    • Microsoft
    • Posts 1,842
    If this is with ASP.NET AJAX Beta 1, please consider: http://forums.asp.net/thread/1441672.aspx

    http://blogs.msdn.com/delay

    This posting is provided "AS IS" with no warranties, and confers no rights.
  • Re: Bug - PopupControlExtender and Wizards

    11-14-2006, 10:58 AM
    • Member
      622 point Member
    • Matt M
    • Member since 08-25-2006, 5:25 PM
    • Eastern WA, USA
    • Posts 128
    The issue is still present with ASP.NET AJAX Beta 2 and AJAX Toolkit build 10374.
  • Re: Bug - PopupControlExtender and Wizards

    11-15-2006, 8:37 PM
    Answer
    • Star
      8,710 point Star
    • David Anson
    • Member since 04-11-2006, 1:39 AM
    • Microsoft
    • Posts 1,842
    Switching your sample from using "visibility: hidden" to "display: none" on the calendar worked for me.

    http://blogs.msdn.com/delay

    This posting is provided "AS IS" with no warranties, and confers no rights.
  • Re: Bug - PopupControlExtender and Wizards

    11-16-2006, 10:42 AM
    • Member
      622 point Member
    • Matt M
    • Member since 08-25-2006, 5:25 PM
    • Eastern WA, USA
    • Posts 128

    David Anson:
    Switching your sample from using "visibility: hidden" to "display: none" on the calendar worked for me.

    This does indeed fix it! I was under the impression not to use "display: none" for the popup control.  Perhaps I was getting it confused with setting visible="false" in the asp.net code.  Visible="false" does indeed cause errors still, due to the control not being present when the control toolkit does its magic.

     

    Thanks! 

  • Re: Bug - PopupControlExtender and Wizards

    11-16-2006, 12:15 PM
    • Star
      8,710 point Star
    • David Anson
    • Member since 04-11-2006, 1:39 AM
    • Microsoft
    • Posts 1,842
    The reason the extra style is needed here to hide the panel (normally PopupControl does this automatically) is because the PopupControl doesn't even exist until the second Wizard step. So it can't hide the panel during load because it hasn't been loaded! By hiding the panel manually, order is restored. :)

    http://blogs.msdn.com/delay

    This posting is provided "AS IS" with no warranties, and confers no rights.
  • Re: Bug - PopupControlExtender and Wizards

    02-21-2007, 1:08 PM
    • Member
      61 point Member
    • jmaag
    • Member since 02-21-2007, 12:43 PM
    • Salt Lake City, UT
    • Posts 22
    I was having this issue with pop-up panels in the wizard in general.  Setting the panel style as you suggested seemed to work nicely.  TY.
Page 1 of 1 (7 items)