Close a window opened using ContentTemplate

3 posts, 1 answers
  1. Stuart Hemming
    Stuart Hemming avatar
    1622 posts
    Member since:
    Jul 2004

    Posted 31 May 2011 Link to this post

    I have a 'regular' RadWindow, one populated using the NavigateUrl property (we'll call this Window1).

    The page that is used to populate it, however, includes a RadWindow (which we'll call Window2) with a <ContentTemplate> tag.

    When the user clicks a button in Window1, Window2 opens. I want to be able to manually close Window2 when the user clicks a button in it, and have the user return to operating in Window1.

    I tried just saying "GetRadWindow().close(), but that closed both Window2 and Window1.

    Any suggestions?

    -- 
    Stuart
  2. Answer
    Georgi Tunev
    Admin
    Georgi Tunev avatar
    7207 posts

    Posted 02 Jun 2011 Link to this post

    Hi Stuart,

    GetRadWindow() is used to get a reference to the RadWindow object from within a content page. If you are using content templates, you need to get a reference to the window object by using $find() or for example, a global variable, set in one of the window's events - OnClientShow, OnClientPageLoad or when opening that window.


    All the best,
    Georgi Tunev
    the Telerik team

    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Stuart Hemming
    Stuart Hemming avatar
    1622 posts
    Member since:
    Jul 2004

    Posted 02 Jun 2011 Link to this post

    Thanks Georgi, I'll give that a shot.

    -- 
    Stuart
Back to Top