RadWindow inside RadWindow.

4 posts, 0 answers
  1. Harish
    Harish avatar
    11 posts
    Member since:
    Jun 2015

    Posted 02 Jul 2015 Link to this post

    Hi All,

    I have used the RadWindow in my code for showing data into pop up. I have used the RadGrid in the RadWindow.

    Now I want to popup another RadWindow popup.

    Can anyone please tell me how to use RadWindow inside RadWindow.

     Thanks,

    Harish Patil

  2. Vessy
    Admin
    Vessy avatar
    1389 posts

    Posted 06 Jul 2015 Link to this post

    Hi Harish,

    I believe the information in the following help article will help you in implementing the desired scenario: How to Open a RadWindow from Within a RadWindow

    Please, take a look at it and let me know in case any further assistance on this matter will be needed.

    Regards,
    Vessy
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Maher
    Maher avatar
    19 posts
    Member since:
    Jul 2015

    Posted 23 Jul 2015 Link to this post

    hi first i will post the answer

    try that demo

    http://demos.telerik.com/aspnet-ajax/window/examples/dialogreturnvalue/defaultcs.aspx

    Code

    Main Page you will have two windows inside one window manager

      <telerik:RadWindowManager ID="RadWindowManager1" runat="server" EnableShadow="true">
                <Windows>
                    <telerik:RadWindow ID="UserListDialog" runat="server" Title="Editing record" Height="320px"
                        Width="310px" Left="150px" ReloadOnShow="true" ShowContentDuringLoad="false"
                        Modal="true">
                    </telerik:RadWindow>
                     
                    <telerik:RadWindow ID="RadWindow1" runat="server" Title="Search" Height="320px"
                        Width="310px" Left="150px" ReloadOnShow="true" ShowContentDuringLoad="false"
                        Modal="true">
                    </telerik:RadWindow>
                </Windows>
            </telerik:RadWindowManager>​​

    code to open the first window from the main

      function ShowEditForm() {     
    window.radopen("first.aspx", "UserListDialog", 1000, 800,30,30);
                    return false;
                }​

    in the second page trans.aspx it is a little bit different

    use this function to get the window

       function GetRadWindow() {
                    var oWindow = null;
                    if (window.radWindow) oWindow = window.radWindow;
                    else if (window.frameElement.radWindow) oWindow = window.frameElement.radWindow;
                    return oWindow;
                }

    this to open the second one

    function openWin2() {
                    var parentPage = GetRadWindow().BrowserWindow;
                    var parentRadWindowManager = parentPage.GetRadWindowManager();
                    window.setTimeout(function () {
                        parentRadWindowManager.open("Second.aspx", "RadWindow1", 400, 400, 30, 30);
                    }, 0);
                }
            

    now i post a question

    in second .aspx(the second rad window) i built a datatable that i need to send to first .aspx(the first rad window)

    i might think to put it on session

    according to this post

    http://www.telerik.com/forums/catching-close-event-server-side

    JS:
    function OnClientClose(sender, args)
    {
     var ajaxManager = $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("Close") ;
    }
    C#:
    protected void RadAjaxManager1_AjaxRequest(object sender, Telerik.Web.UI.AjaxRequestEventArgs e)
    {
      if (e.Argument == "Close")
      {//you code Put the session
      }
    }

    this code will be in the main page or first .aspx ot the main since that the ajaxmanager on main

    how to open the datatable (or the session on first.aspx)

     

    thanks

  5. Vessy
    Admin
    Vessy avatar
    1389 posts

    Posted 28 Jul 2015 Link to this post

    Hi Maher,

    If I understand the scenario properly, you have two RadWindows on a page, loading their content from two external pages and you want to retrieve information from the one window to the other. If so, You can pass parameters between the Windows. Here is the help article and demo which explains the same:
    Using RadWindow as a Dialog.
    Window / Returning Values from a Dialog.
    Call a Function from a RadWindow in Another RadWindow

    Regards,
    Vessy
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top