GanttView allows users to load the contents along with the layout from an XML file. This feature is available to users at runtime through the Load button available on the toolbar. Clicking the Load button opens the Load from XML file dialog that lets you load the XML file. In addition, GanttView provides ImportFromMsProjectXml method to load project schedules from Microsoft Project.
The functionality to load content from an XML file can also be achieved programmatically through the LoadXml method of the C1GanttView class. The LoadXml method provides three overloads for loading the contents as listed below.
Overloads | Description |
LoadXml (String) | To load the contents from an XML file. |
LoadXml (Stream) | To save the contents from an IO stream object. |
LoadXml (StreamWriter) | To save the contents from an XmlWriter object. |
The following code illustrates how the LoadXml method can be used to load the contents from an XML file.