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.
Unfortunately, activation email could not send to your email. Please try again.

AppStateSerializer

Thread ID:

Created:

Updated:

Platform:

Replies:

39197 Dec 29,2005 04:08 PM Jan 5,2006 06:47 PM Windows Forms 2
loading
Tags: Tools
Narendra Maharaj
Asked On December 29, 2005 04:08 PM

I have an MDI app with two DockingManagers. How can I persist both DockingManagers states then retrieve them? I''d like to use an AppStateSerializer. I''m using VS 2005, Syncfusion 4.1beta with the 2.0 dll''s and C#.

Vijayanand S [Syncfusion]
Replied On January 2, 2006 01:21 AM

Hi Narendra, You could save/load the dock state using the AppStateSerializer as in the following code snippet: //Serializing AppStateSerializer aser = new AppStateSerializer(SerializeMode.XMLFile, Application.StartupPath + System.IO.Path.DirectorySeparatorChar + fileName); this.dockingManager1.SaveDockState(aser); aser.PersistNow(); //De-Serializing. Make sure it doesnt go into an infinite loop when used in NewDockStateEndLoad event handler. AppStateSerializer aser = new AppStateSerializer(SerializeMode.XMLFile, Application.StartupPath + System.IO.Path.DirectorySeparatorChar + fileName); this.dockingManager1.LoadDockState(aser); You could refer to our Docking Package samples: UserControlContainer or MDIContainerControl Demo at the following location "[InstalledDerive]:\Program Files\Syncfusion\Essential Studio\4.1.0.10\windows\Tools.Windows\Samples\Docking Package\ContainerControlSupportDemo\" to save or restore the multiple docking managers state information. However I have created a test sample to show the procedure to save or load the information about the docking state.Please take a look at the attached sample and let me know if you have any questions. Thank you for your interest in Syncfusion products. Regards, Vijay Test Sample

Narendra Maharaj
Replied On January 5, 2006 06:47 PM

Thanks Vijay I was doing a appStateSerializer.PersistNow() twice. It works now.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;