Need solution: Issue with RadWindow Size...

4 posts, 0 answers
  1. Kishore Amireddy
    Kishore Amireddy avatar
    4 posts
    Member since:
    Dec 2009

    Posted 05 Jan 2010 Link to this post

    We have a Telerik Tabs in which we have 1 RadGrid in each of them. On click of each grids rows we open a RadWindow as shown below.

     

    <telerik:RadWindowManager ID="test RadWindowManager " DestroyOnClose="true" ReloadOnShow="true" runat="server" VisibleStatusbar="false" 
                    Behaviors="Close,Move, Resize" ShowContentDuringLoad="true" Modal="True" Width="1004px" 
                    Height="550px" Top="5px" Left="0px">  
                    <Windows> 
                        <telerik:RadWindow ID="RadWindow1" DestroyOnClose="true" ReloadOnShow="true" runat="server" VisibleStatusbar="false" Behaviors="Close,Move, Resize" 
                            ShowContentDuringLoad="true" Width="1004px" Height="550px" Top="5px" Left="0px">  
                        </telerik:RadWindow> 
                    </Windows> 
                </telerik:RadWindowManager> 
     

     

    Now when the user clicks a RadGrid row in side tab1 opens up properly and when user clicks other RadGrid row in tab2 say on which we need to open a RadWindow opens up but with all the same properties of RadWindow placed in tab 1.

     

    We need separate properties like say Width and Height of the RadWindow openned from different tabs. Basically same properties are being set to the RadWindows in other tabs too which we don’t want. We want to give separate Width and Height for every RadWindow placed in the same page(AJAXified).

     

    Request you to provide the necessary steps to do to resolve this issue.

     

    Your speedy response will be deeply appriated.

     

    Regards,

    Kishore Amireddy

  2. Svetlina Anati
    Admin
    Svetlina Anati avatar
    2795 posts

    Posted 06 Jan 2010 Link to this post

    Hello Kishore,

    I already answered your other thread and for your convenience and for others who might have the same question I pasted my reply below:

    The provided code snippet does not show how exactly you open the RadWindows but I assume that you do so by using the radopen function. If so, you should reference the RadWindow there and use the client-side method setSize to set the desired different size, e,g as shown below:

    var oWnd = radopen(url, WindowName);
    oWnd.setSize(myWidth, myHeight);

    Let me know if you need further assistance.


    Regards,
    Svetlina
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  3. Kishore Amireddy
    Kishore Amireddy avatar
    4 posts
    Member since:
    Dec 2009

    Posted 12 Jan 2010 Link to this post

    Hi Telerik Team,

    Thanks for the response. But sadly your solution has not helped us resolve our issue.

    We are still getting all the width and Height properties set in the first RadWindow to the subsequent Rad Windows.

    Please provide us any alternate solution.

    Regards
    Kishore
  4. Svetlina Anati
    Admin
    Svetlina Anati avatar
    2795 posts

    Posted 14 Jan 2010 Link to this post

    Hi Kishore,

    I built up a test demo on my side but everything works as expected - please take a look at the following code:

    <%@ Page Language="C#" %>
      
    <%@ Register TagPrefix="telerik" Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <head runat="server">
        <title>Untitled Page</title>
    </head>
    <body>
        <form id="form1" runat="server">
            <asp:ScriptManager ID="mng" runat="server">
            </asp:ScriptManager>
      
            <script type="text/javascript">
         var width = 200;
         var height = 200;
         function OpenWnd()
         {
                var oWindow = window.radopen('NewPage.aspx', null);
                oWindow.setSize(width, height);   
                width += 100;
                height += 100;  
         }
            </script>
      
            <telerik:RadWindowManager ID="mng1" runat="server" Width="300" Height="300">
            </telerik:RadWindowManager>
            <asp:Button ID="btn" runat="server" Text="Open RadWindow" OnClientClick="OpenWnd();return false;" />
        </form>
    </body>
    </html>

    It opens a RadWindow with different size everytime no matter the manager has explicit size set.

    If the problem persists, please modify the code in ordre to reproduce the problem (make sure it can be directly run as the one above) and share it here. Once I receive it, I will built up a test demo based on it and I will do my best to help.

    Note, that I have tested with the 2009.3.1208 version of RadControls for ASP.NET AJAX - if you are by any chance using another version, let me know.


    Best wishes,
    Svetlina
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Back to Top