WebToolBar provides method to save and load structure from xml file.
This topic will show you how to save and load structure programmatically.
To save and load structure programmatically
- Create two ASP.NET button controls.
- Place the following code in the first button Click event to save WebToolBar's structure.
C#
Copy Codeprotected void WebButton1_Clicked(object sender, ISNet.WebUI.WebDesktop.WebButtonClickedEventArgs e) { WebToolBar1.SaveCommandsStructureToXml(Server.MapPath("SampleStructure.xml")); }
- Place the following code in the second button Click event to load WebToolBar's structure.
C#
Copy Codeprotected void WebButton2_Clicked(object sender, ISNet.WebUI.WebDesktop.WebButtonClickedEventArgs e) { WebToolBar1.LoadCommandsStructureToXml(Server.MapPath("SampleStructure.xml")); }