Show contents 

Visualizators > Visualizators Assembly Interfaces > IVZDataVisualizer > IVZDataVisualizer.SaveStyleToXml

IVZDataVisualizer.SaveStyleToXml

Syntax

SaveStyleToXml: String;

Description

The SaveStyleToXml method saves parameters of visualizer style to XML file.

Example

Executing the example requires that the repository contains an express report with the EXP identifier. The unit containing the example should have links to the Express, Metabase, Drawing and Visualizators system assemblies. The specified procedure should be called from the Main entry point.

Before executing this example, the bubble tree looks as shown on the IVZBubbleTree interface description page. Let get style parameters in XML format for the bubble tree, change the color of orbits and set changed style parameters from XML file:

Sub UserProc;
Var
    Metabase: IMetabase;
    EaxAnalyzer: IEaxAnalyzer;
    BubbleTree: IVZBubbleTree;
    BubbleTreeStyleXML: String;
Begin
    // Get the current repository
    Metabase := MetabaseClass.Active;
    // Get express report
    EaxAnalyzer := Metabase.ItemById("EXP").Edit As IEaxAnalyzer;
    // Get bubble tree
    BubbleTree := EaxAnalyzer.BubbleTree.BubbleTree;
    // Get bubble tree style settings in XML format and change orbits color
    BubbleTreeStyleXML := String.Replace(BubbleTree.SaveStyleToXml, 
        "OrbitsPen Style=""solid"" Color=""#ffe0e0e0"""
        "OrbitsPen Style=""solid"" Color=""#ff000000""");
    // Set new values for bubble tree style settings from XML file
    BubbleTree.LoadStyleFromXml(BubbleTreeStyleXML);
    // Get express report
    (EaxAnalyzer As IMetabaseObject).Save;
End Sub UserProc;

After executing the example the color of orbits is changed:

See also:

IVZDataVisualizer