We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Docking Manager

I have read through many articles about how to programatically work with the docking manager and it's windows. I am trying to something a little unique I think and was hoping for some guidance. I wish to store in a table in sql server some information that would pertain to dockable windows. I would at runtime retrieve this info and programatically create a panel and add it to the dockingmanger and then do something on this panel. Now, the trick is I want to preserve state somehow. I could have for example 50 possible floating windows, and this user may choose to view 3 of them. I don't want to instantiate 50 at design time when this particular user only uses 3. So I want to store the fact the user wants one of these floating windows and then on load, create them on the fly and re-position them to where they last were stored. Is this possible? Thanks

4 Replies

AD Administrator Syncfusion Team August 28, 2003 07:27 PM UTC

Hi Mike, In our docking windows architecture, persisted dockstate information is restored using the relative position of each control as compared to other controls. Retrieving persisted docking information for individual controls is not possible. This is because attempting to get hold of the control to which the particular control is docked and using that to restore the docked state will work only as long as the layout is identical to the state that it was in when the info was extracted. Any changes such as if the parent/sibling had been moved around or redocked would result in a totally unexpected state. Regards, Guru Patwal.

AD Administrator Syncfusion Team August 29, 2003 09:35 AM UTC

Hi Mike, We have decided to accomodate your request and have logged this as a high priority 'feature request' (QA# 242). We will try our very best to include this feature in the future releases of Essential Tools. Regards, Guru Patwal.

MI Mike September 10, 2003 05:33 PM UTC

Thanks Guru, We are trying to go ahead with a strategy based on this enhancement. Could you give me a quick overview of how this might work using a DB to store individual window state? I am trying to figure out how to best code for this. We are imagining a preference ParentBarItem in our Main Menu that would have many options that if you clicked them it would launch a particular control and add it to the docking manager. The user could then position this where they want on their form and it would persist the next time they start the app. We would have a possiblity of say 20 controls that are dockable - all of these happen to be tree controls. Please advise if this seems reasonable and doable and when you might expect this support to be ready. Thanks Michael

AD Administrator Syncfusion Team September 10, 2003 09:05 PM UTC

Hi Mike, The persistence mechanism for saving docking information of individual controls would still be the same using the AppStateSerializer and SerializeMode. The persistence information can be stored using the following SerializeMode values : 1.BinaryFile 2.XMLFile 3.XMLFmtStream 4.IsolatedStorage 5.WindowsRegistry 6.BinaryFmtStream Yes, your implementation seems reasonable and doable with the new docking windows persistence functions. We will have this feature available in the latest build of Essential Suite which is scheduled for release in about two weeks from now. Regards, Guru Patwal.

Live Chat Icon For mobile
Up arrow icon