Load Dock layout from cookie on page load

2 posts, 0 answers
  1. Nigel
    Nigel avatar
    13 posts
    Member since:
    Aug 2007

    Posted 08 Oct 2007 Link to this post

    Hi

    I've used the code on the Demo page to save/load state of RadDockLayout in a cookie and this works on postback - but how do I set the layout by reading the cookie on the initial page load - (the items in the dock are being created dynamically in the OnInit)

    I have read the portal demo and see how it's done using a database - but hopefully a simple cookie is all I need.

    Regards

    Nigel
  2. Petya
    Admin
    Petya avatar
    869 posts

    Posted 08 Oct 2007 Link to this post

    Hello Nigel,

    Initially you can create the docks in PageLoad - make sure you do so on !IsPostback. On postback they should be recreated in PageInit and since in PageLoad you have used !IsPostback, they will not be recreated twice. Hope this answers your question.

    Regards,
    Petya
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
Back to Top