Note that there are some explanatory texts on larger screens.

plurals
  1. POHow to close the parent window from its child?
    primarykey
    data
    text
    <p>I have the following case:</p> <p>I have a gridview on my page :</p> <pre><code>page1.aspx </code></pre> <p>I open another page(<code>page2.aspx</code>) through that gridview in a <a href="http://demos.telerik.com/aspnet-ajax/window/examples/contenttemplatevsnavigateurl/defaultcs.aspx">rad window</a> then after that,through some button on <code>page2.aspx</code> i open the last page (<code>page3.aspx</code>) in a <code>rad window</code> also.</p> <p>all these steps are performed through server side code :</p> <hr> <pre><code> protected void OpenNewWindow(string url, int width, int height, int mode) { RadWindow newWindow = new RadWindow(); newWindow.NavigateUrl = url; newWindow.VisibleOnPageLoad = true; newWindow.KeepInScreenBounds = true; newWindow.Skin = "Metro"; if (width &gt; 0) { newWindow.Width = width; } if (height &gt; 0) { newWindow.Height = height; } newWindow.VisibleStatusbar = false; if (mode == 0) { { } //newWindow.OnClientClose = "OnChildWindowClosed"; newWindow.DestroyOnClose = true; newWindow.InitialBehaviors = WindowBehaviors.Maximize; } RadWindowManager1.Windows.Add(newWindow); } </code></pre> <hr> <p>What i want to do is :</p> <p>when clicking on a specific button on my (<code>page3.aspx</code>) close it and its parent <code>page2.aspx</code>.</p> <p>How to do this (server side)?</p> <p>I try this :but it just closes the child <code>page3.aspx</code> i want to close the parent <code>page2.aspx</code> also ?!</p> <hr> <pre><code> protected void Button1_Click(object sender, EventArgs e) { ((RadAjaxManager)this.Parent.FindControl("RadAjaxManager1")).ResponseScripts.Add("CloseModal();"); RadAjaxManager1.ResponseScripts.Add("CloseModal();"); } </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload