This is a migrated thread and some comments may be shown as answers.

[Solved] parent window close problem

1 Answer 129 Views
Window
This is a migrated thread and some comments may be shown as answers.
bankey
Top achievements
Rank 1
bankey asked on 03 Jun 2008, 11:15 PM
Hi

i want to know how to close parent window.
i m using
parent.close but it not working.

1 Answer, 1 is accepted

Sort by
0
Georgi Tunev
Telerik team
answered on 04 Jun 2008, 05:28 AM
Hello bankey,

To close a RadWindow with code, you need to get a reference to the wrapper by using the GetRadWindow() function and then to call its close method:

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

I hope this helps.


Regards,
Georgi Tunev
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
Window
Asked by
bankey
Top achievements
Rank 1
Answers by
Georgi Tunev
Telerik team
Share this question
or