RadDock Saving position when items is moved on client side with Javascript

2 posts, 0 answers
  1. Ralphael
    Ralphael avatar
    1 posts
    Member since:
    Aug 2011

    Posted 10 Oct 2011 Link to this post

    I have an issue on how to save the layout of all RadDock controls on a web page when a RadDock is moved to a new location. Currently, I have server side code that saves the users layout position to the database. However, the user must click a command button to save layout. However, the user wants the application to save the new layout when a RadDock is closed or moved to a new location. Is this possible.
  2. Slav
    Slav avatar
    1359 posts

    Posted 13 Oct 2011 Link to this post

    Hello Ralphael,

    Please note that the API of RadDockLayout provides developers with the ability to save the positions of the dock objects on the page in various storage mediums. To accomplish such scenario you should use the LoadDockLayout and SaveDockLayout events. Then, if you set the properties of the RadDock AutoPostBack and CommandsAutoPostBack to true, you will ensure that a postback will be executed every time a dock control is moved or a command is clicked, which will lead to saving and loading the RadDocks' layout.

    You can refer to the online demo Dynamically Created Docks, which implements the described approach, for incorporating the desired feature into your actual project.

    I hope the provided information will help you with your scenario. Feel free to contact us again if you encounter additional difficulties.

    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
Back to Top