Hi Vikram,
According to my understanding you wish to close the docking window when its "X" close button is pressed and not just hide it. You could do so by handling the DockingManager''s DockVisibility method as shown in the code below :
private void dockingManager1_DockVisibilityChanged(object sender, Syncfusion.Windows.Forms.Tools.DockVisibilityChangedEventArgs arg)
{ this.dockingManager1.SetEnableDocking(arg.Control, false);
this.Controls.Remove(arg.Control);
arg.Control.Dispose();
}
You should first remove the docked control from the DockingManager''s Controls list, and then from the Form''s Controls list. And finally you should call the Dispose emthod on that control. I have created a
sample_application here which illustrates how to do this. The main menu has options to save/load state information. Save the state informtaion, close the docking windows, and try to load them. Nothing comes up. This is because the docking windows were destroyed when "closed" and not hidden. Please let me know if I have not understood your requirements correctly. Thanks for considering Syncfusion products.
Regards,
Guru Patwal
Syncfusion, Inc.