[]
Reconstructs a SharpGraph object with a specified state from an XML encoding.
Use "strict" attribute of root element "SharpGraph" in xml files to control error handling behaviour. This attribute is false by default. If true xml import process will stop once it finds first error and throw an exception. If false it will mutually continue.
public static void FromXml(ISharpGraph sharpChartControl, XmlElement rootElement)
| Type | Name | Description |
|---|---|---|
| ISharpGraph | sharpChartControl | |
| XmlElement | rootElement | The XML encoding to use to reconstruct the SharpGraph object. |
Reconstructs a chart from its XML representation, populating the supplied control. Use the
includeData flag to control whether bound data is restored along with the layout.
public static void FromXml(ISharpGraph sharpChartControl, XmlElement rootElement, bool includeData)
| Type | Name | Description |
|---|---|---|
| ISharpGraph | sharpChartControl | The chart control to populate from the XML. |
| XmlElement | rootElement | The root XML element previously produced when the chart was serialized. |
| bool | includeData | true to also restore data-related content; false to restore only the chart definition. |
If the root element carries a strict attribute set to true, deserialization failures are
rethrown; otherwise individual property failures are ignored and import continues.
Reconstructs a SharpGraph object with a specified state from an XML encoding.
public static void FromXml(ISharpGraph sharpChartControl, string fileName)
| Type | Name | Description |
|---|---|---|
| ISharpGraph | sharpChartControl | |
| string | fileName | The XML file name to use to reconstruct the SharpGraph object. |
Reconstructs a chart from an XML file, populating the supplied control. Use the
includeData flag to control whether bound data is restored along with the layout.
public static void FromXml(ISharpGraph sharpChartControl, string fileName, bool includeData)
| Type | Name | Description |
|---|---|---|
| ISharpGraph | sharpChartControl | The chart control to populate from the file. |
| string | fileName | The path of the XML file previously produced when the chart was serialized. |
| bool | includeData | true to also restore data-related content; false to restore only the chart definition. |