Hi Surya,
Thanks for using Syncfusion products.
You can use the SaveTabGroupStates() and LoadTabGroupStates()methods for save and retrieve the tab states in TabbedMDI. This states are stored in default storage location called Isoloated Storage(C:\Documents and Settings\LoginName\Local Settings\Application Data\IsolatedStorage).
Isolated storage is a data storage mechanism that provides isolation and safety by defining standardized ways of associating code with saved data.With isolated storage, your code no longer needs unique paths to specify safe locations in the file system and data is protected from other applications that only have isolated storage access.
//Call in form load event
this.tabbedMdiManager.LoadTabGroupStates();
//Call in form closing event
this.tabbedMdiManager.SaveTabGroupStates();
Another approach here would be to use a different storage format by using the SerializeMode enumerator in the AppStateSerializer as shown below :
private void Form1_Load(object sender, System.EventArgs e)
{
AppStateSerializer aser = new AppStateSerializer(SerializeMode.XMLFile, "..\\..\\stateinfo");
this.tabbedMdiManager.LoadTabGroupStates(aser);
MessageBox.Show("ha");
}
private void Form1_Closing(object sender, System.ComponentModel.CancelEventArgs e)
{
AppStateSerializer aser = new AppStateSerializer(SerializeMode.XMLFile, "..\\..\\stateinfo");
this.tabbedMdiManager.SaveTabGroupStates(aser);
aser.PersistNow();
}
But it doesn't save the child forms that are created at runtime. This has to be done by ourself within our application. When forms are loaded at runtime, before calling LoadTabGroupStates all the forms has to be opened. So before calling this, we have to load all the form that are opened previously. So we have to save the child form that are opened previously information by ourself.
Here is sample for TabState Persistion:
test samplePlease let me know if you have any queries.
Regards,
S.Gopal.