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

Resetting toolbar positions for MSI children

Is it possible to reset the toolbar positions for MDI child windows?

1 Reply

MJ Mano J Syncfusion Team March 17, 2006 02:15 PM UTC

Hi Paul, There is no direct way of resetting the childform bar positions, as the MainFrameBarManager alone has the LoadDesignerBarState method which is used to reset the bar postions in the mainform. One way is, you can save the bar state in the form_load event using AppStateSerializer for resetting it later. private void Form1_Load(object sender, System.EventArgs e) { // Child Form Form2 frm= new Form2(); frm.MdiParent = this; frm.Show(); // Save the BarState using AppStateSerializer AppStateSerializer app = new AppStateSerializer(SerializeMode.XMLFile, "..\\..\\ResetStatePersist"); this.mainFrameBarManager1.SaveBarState(app); app.PersistNow(); } private void ResetButton_Click(object sender, System.EventArgs e) { AppStateSerializer app = new AppStateSerializer(SerializeMode.XMLFile, "..\\..\\ResetStatePersist"); this.mainFrameBarManager1.LoadBarState(app); } I have attached a sample that shows this completely. Change the position of the toolBars and click the "Reset" button to reset(load state) the Bar positions. Please let me know if this helps you. Thanks for using Syncfusion products. Regards, Mano Resetbarpostions_F41970.zip

Loader.
Live Chat Icon For mobile
Up arrow icon