Loading and Saving Charts, Data, and Images

In C1Chart each chart can be loaded from and saved to an external XML file or a string value. In addition, the chart can be saved to any number of image files, which allows more flexibility in archiving, accessing data, and creating images of the chart. 

There are two different methods that can be used to save/load the chart to an XML file or string value by either saving/loading the entire chart (data and formatting)or by saving/loading only the chart's data.

Saving/Loading chart’s styles and data

When the entire chart is saved/loaded, all of the formatting of the axis, the titles, and the chart area is saved to an XML file.

The following methods are used when saving the chart’s formatting and data:

      LoadChartFromFile

      SaveChartToFile

      LoadChartFromString

      SaveChartToString

In cases where you need to save or load the background images from the chart elements such as the chart background, header and footer images, etc. you can use the following save/load methods:

      LoadChartAndImagesFromFile

      SaveChartAndImagesToFile

      LoadChartAndImagesFromString

      SaveChartAndImagesToString

Saving/Loading chart’s data

When only the chart's data is saved/loaded the external file is smaller in size, but when this file is loaded back into the chart, only the data will be restored.

The following methods are used when saving/loading only the chart’s data:

      SaveDataToFile

      LoadDataFromFile


Send us comments about this topic.
Copyright © GrapeCity, inc. All rights reserved.