Value: Variant;
The Value property determines the value, corresponding to all visualizer items.
The Value property is used in case, if the MappingType property has the value of the VisualizatorDataMappingType constant transformation.
Executing the example requires that the repository contains an express report with the EXPRESS_REPORT identifier containing bubble tree. Set a constant transformation as one color for visualizer.
Add links to the Metabase, Express, Drawing, Visualizators system assemblies. The specified procedure should be called from the Main entry point.
Sub UsecProc;
Var
Metabase: IMetabase; // Repository
EaxAnalyzer: IEaxAnalyzer; // Express report
BubbleTree: IVZBubbleTree; // Bubble tree
ColorVisual: IVZColorVisual; // Color visualizator
DataSourceMapping: IVZDataSourceMapping; // Settings used for data mapping with colors
Brush: IGxSolidBrush;
Begin
// Get repository object
Metabase := MetabaseClass.Active;
// Get express report object
EaxAnalyzer := Metabase.ItemById("EXPRESS_REPORT").Edit As IEaxAnalyzer;
// Get bubble tree
BubbleTree := EaxAnalyzer.BubbleTree.BubbleTree;
// Get visualizer colors
ColorVisual := BubbleTree.ColorVisual;
// Get settings used for data mapping
DataSourceMapping := ColorVisual.ColorMapping;
// Set constant transformation
DataSourceMapping.MappingType := VisualizatorDataMappingType.DataMappingConstant;
// Determine blue color for bubble tree elements
Brush := New GxSolidBrush.Create(New GxColor.CreateRGB(0, 255, 255));
DataSourceMapping.Value := Brush;
// Display the type of data mapping to the console
Debug.WriteLine("Data mapping type: " + DataSourceMapping.MappingType.ToString);
// Save changes in express report
(EaxAnalyzer As IMetabaseObject).Save;
End Sub UsecProc;
After executing the example, the bubble tree elements will be displayed using the specified color in the express report. The console will display the type of data mapping:
Data mapping type: 2
See also: