Page in RadWindow loads twice

2 posts, 0 answers
  1. Danny Scheelings
    Danny Scheelings avatar
    69 posts
    Member since:
    Jan 2006

    Posted 25 Mar 2010 Link to this post


    I think I have found a bug in the 2009 Q2 and Q3 versions. See below the code example:

    <telerik:RadWindow ID="win" runat="server" ReloadOnShow="true" /> 
    <asp:HyperLink runat="server" ID="hl" Text="Click" NavigateUrl="javascript:var w=OpenWin();" /> 
    <script type="text/javascript">  
        function OpenWin()  
            var w = $find("win");  
        function WinResult(sender, args)  
            //Remove window closed handler  

    When I click the hyperlink, the Window is opened with the URL '/Default.aspx'. When the Window is closed the WinResult javascript function is called.

    The problem is that the Default.aspx page is loaded twice in the RadWindow. When I remove the RadWindow property ReloadOnShow ór when I remove the last line the from  the javascript function WinResult "sender.remove_close(WinResult)", this problem does not occur.

    From one of the Telerik experts I heard that it is actually necessary to call that remove_close method on the RadWindow object to prevent executing the script more than once. So, what can I do to prevent loading the Default.aspx page twice in the RadWindow.

  2. Georgi Tunev
    Georgi Tunev avatar
    7207 posts

    Posted 26 Mar 2010 Link to this post

    Hi Danny,

    When ReloadOnShow is set to true, the page inside RadWindow will always be reloaded when you show that window - this is expected behavior.

    All the best,
    Georgi Tunev
    the Telerik team

    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 Public Issue Tracking system and vote to affect the priority of the items.
Back to Top