Telerik RadWindow keep it open

8 posts, 0 answers
  1. Ravi
    Ravi avatar
    7 posts
    Member since:
    Nov 2010

    Posted 24 Nov 2011 Link to this post

    Hi,
    Here is my scenario:
    Parent page:
    I have a text box and a button for search feature.  Once I click the button I am opening a radwindow by javascript. Works fine and I display the results in a grid.  Now when I click on one result it should refresh the parent page with the selected value.  Works fine.

    The problem:
    When I click on the result and Parent page refreshes but it closes the RadWindow that's been opened.  I do want to keep this radwindow till I decide close it.  This way I can refer back to the results and view each result in the parent page.  How would I keep the rad window open all the time (Not loosing it when the parent page refreshes).  Please advise.

    Thanks,
  2. Marin Bratanov
    Admin
    Marin Bratanov avatar
    4658 posts

    Posted 25 Nov 2011 Link to this post

    Hi Ravi,

    The RadWindow is entirely a client-side object, its UI is created via JavaScript when it needs to be shown. This allows us to greatly reduce the markup that needs to be sent from the server, especially in cases where many RadWindows are needed.

    This also means that since the control has no server rendering there is no way to persist it across postbacks that dispose the entire page on the client.

    What you can do is use AJAX - the postback from the Grid can update the grid and the other panel that shows information (both placed in UpdatePanels), thus disposing only these parts of the page and leaving the RadWindow out of the response.


    All the best,
    Marin
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now
  3. Ravi
    Ravi avatar
    7 posts
    Member since:
    Nov 2010

    Posted 25 Nov 2011 Link to this post

    Marin,
    Thank you for your response.  I did really thought of that using Ajax to update panels but in my case I will be clicking on several links on the parent page yet I would want to keep the radwindow open still.  Would you have any other suggestion for this kind of scenario?  
  4. Dobromir
    Admin
    Dobromir avatar
    1633 posts

    Posted 28 Nov 2011 Link to this post

    Hi Ravi,

    To preserve the state of RadWindow opened on client using JavaScript, I would suggest you to use a hidden field to store the window's current state. And then on the server set the RadWindow's VisibleOnPageLoad property according to the value of this hidden field. For your convenience I have attached a sample page demonstrating this approach.

    Also, if you are using RadWindowManager on the page do display RadWindows, you can set PreserveClientState property to true.

    I hope this helps.

    Greetings,
    Dobromir
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now
  5. Tim
    Tim avatar
    3 posts
    Member since:
    Jun 2014

    Posted 18 Jun 2014 in reply to Marin Bratanov Link to this post

    Thanks Marin,

    This is what I need, to keep the pop up window (which contains its own grid) open on a click, so they can sort columns, etc.  Do you have an example of how we would structure this?

    Thanks,

    Tim
  6. Marin Bratanov
    Admin
    Marin Bratanov avatar
    4658 posts

    Posted 18 Jun 2014 Link to this post

    Hi Tim,

    I believe this article will help: http://www.telerik.com/help/aspnet-ajax/window-ajaxifying.html.

    You may also find useful this one on opening it from the server: http://www.telerik.com/help/aspnet-ajax/window-troubleshooting-opening-from-server.html.


    Regards,

    Marin Bratanov
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  7. Kiran
    Kiran  avatar
    40 posts
    Member since:
    Oct 2018

    Posted 01 May in reply to Dobromir Link to this post

    Hi,

    I tried setting the PreserveClientState="true". This only keeps the radwindow open even when the main page refreshes but does not retain the web page it is directed to. It just behaved it was an empty radwindow. Is using an update panel mandatory to keep the radwindow open and refreshing when the main refreshes?

  8. Rumen
    Admin
    Rumen avatar
    13949 posts

    Posted 06 May Link to this post

    Hi Kiran,

    The PreserveClientState property sets a value indicating whether the RadWindow objects' state (size, location, behavior) will be persisted in a client cookie to restore state over page postbacks/visits. It does not take care of the page refresh in the content area iframe of RadWindow.

    If you want to reload the page, check out these posts:
    https://www.telerik.com/forums/how-to-refresh-the-page-click-button-close-radwindow#3M7pIo_VQEmdi4cIdvzm6A
    https://stackoverflow.com/questions/20286959/how-to-refresh-the-page-click-button-close-radwindow
    https://www.telerik.com/forums/refreshing-radwindow.

    In case, you need further assistance, please provide an example or a simple runnable project of your scenario so that we can get a better overview of it.

    Best regards,
    Rumen
    Progress Telerik
    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Back to Top