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

Close Rad Window after ajax calls

1 Answer 75 Views
Window
This is a migrated thread and some comments may be shown as answers.
p
Top achievements
Rank 1
p asked on 09 Feb 2010, 12:57 AM
Hi,

I need to close a rad window after making an ajax call.

 
            function closeandredirect() { 
                GetRadWindow().BrowserWindow.location.href = '/main/sdfds_Select.aspx'
                GetRadWindow().close();       //closes the window      
            } 
            function GetRadWindow() { 
                var oWindow = null
                if (window.radWindow) 
                    oWindow = window.radWindow; 
                else if (window.frameElement.radWindow) 
                    oWindow = window.frameElement.radWindow; 
                return oWindow; 
            }  

                lblCloseWindow.Text = "<script type='text/javascript'>closeandredirect();</script>"
                lblCloseWindow.Visible = true

I tried using the above code. and did not work for me.
But it does work if i change the EnableAJAX  property of radajaxmaanger to false.


1 Answer, 1 is accepted

Sort by
0
Georgi Tunev
Telerik team
answered on 09 Feb 2010, 06:37 AM
Hi p,

I believe that the following blog post will be of help:
http://blogs.telerik.com/supportdept/posts/09-05-05/executing_javascript_function_from_server-side_code.aspx


Greetings,
Georgi Tunev
the Telerik team

Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Follow the status of features or bugs in PITS and vote for them to affect their priority.
Tags
Window
Asked by
p
Top achievements
Rank 1
Answers by
Georgi Tunev
Telerik team
Share this question
or