Auto resize no working

2 posts, 0 answers
  1. Allen
    Allen avatar
    111 posts
    Member since:
    Apr 2012

    Posted 06 Feb 2013 Link to this post

    The modal is not resizing.  Please refer to the PNG file.
    Here is my code:
    <telerik:RadWindow ID="RadWindow2" runat="server"
                                                                            Modal="True" Behaviors="Move, Reload" Title="     Recurrence"
                                                                            AutoSize="True" ForeColor="White"
                                                                            AutoSizeBehaviors="Width, Height, Default" ReloadOnShow="True">
                                                                            <p align="left">
                                                                                    <asp:RadioButtonList ID="RadioButtonList1" runat="server">
                                                                                        <asp:ListItem Value="ThisWeekOnly" Selected="True">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Selected Week</asp:ListItem>
                                                                                        <asp:ListItem Value="Forever" >&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Forever</asp:ListItem>
                                                                                        <asp:ListItem Value="Forever" >&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Vocation !!!</asp:ListItem>
                                                                                        <asp:ListItem Value="Forever" >&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;More Vocation !!!!</asp:ListItem>
                                                                                        <asp:ListItem Value="Forever" >&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Even More Vocation !!!!!</asp:ListItem>
                                                                                <asp:Button ID="btnSubmit" runat="server" Text="Submit"
                                                                                    BackColor="#CC0000" BorderStyle="Outset"
                                                                                    UseSubmitBehavior="False" EnableTheming="True" OnClick="btnSubmit_Click"/>
                                                                                <asp:Button ID="Cancelbtn" runat="server" BackColor="#CC0000"
                                                                                                BorderStyle="Outset" Font-Bold="True" ForeColor="White" Text="Cancel"
                                                                                                UseSubmitBehavior="False" />


  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 07 Feb 2013 Link to this post

    Hi Allen

    Merely setting the AutoSize property of the RadWindow to true is not always sufficient for this functionality to work as expected.

    The content placed in the RadWindow needs to have explicit dimensions set in pixels. This is necessary, as otherwise you get a confrontation of concepts - a block element (such as the asp Panel, or div, or table) by default takes the width of its parent - 100% of it.
    This means that it tries to autosize according to the RadWindow. In the same time we want the RadWindow to autosize itself according to this element, which leads to this obvious contradiction.

     This is the reason why some explicit dimensions must exist in the content. Therefore one of the best solutions is adding an empty div with no content or borders that has explicit width - it will not be visible, yet it will allow the RadWindow to autosize correctly.

    For more information check the following help documentation
    Autosizing Issues

Back to Top