GanttView not only lets you save the project schedules but also lets you load them from XML files and MS Projects. Loading the saved layouts also helps in reducing your time and effort in re-creating the same structure.
To load project schedules from an XML document, you can simply call LoadXml method of the C1GanttView class and parse name of the XML document as a parameter.
Use the code below to load contents from an XML document.
C# |
コードのコピー
|
---|---|
//「gantt.xml」ファイルからコンテンツをインポートします。 if (File.Exists("gantt.xml")) { gv.LoadXml("gantt.xml"); } |
The GanttView control supports importing MS Project XML to GanttView by using ImportFromMsProjectXml method of the C1GanttView class. The ImportFromMsProjectXml method takes the file name as its parameter and imports it.
The following code imports the project schedules from an MS project.
C# |
コードのコピー
|
---|---|
//「ganttMSProject.xml」ファイルからコンテンツをインポートします。 if (File.Exists("ganttMSProject.xml")) { gv.ImportFromMsProjectXml("ganttMSProject.xml"); } |