IPPSpeedometerScale.BorderWidth

Syntax

BorderWidth: Double;

Description

The BorderWidth property determines width of scale border.

Comments

The BorderWidth property is relevant if the IPPSpeedometerScale.EnableBorder property is set to True.

Example

Executing the example requires that the repository contains a database with the ADHOC identifier. A dashboard must contain a speedometer.

Add links to the Adhoc, Drawing, Express, Metabase, Speedometer system assemblies.

Sub UserProc;
Var
    Speedometer: IPPSpeedometer;
    MB: IMetabase;
    AdhocReport: IAdhocReport;
    EaxSpeedometer: IEaxSpeedometer;
    Enalyzer: IEaxAnalyzer;
    DsObjs: IAdhocDataSourceObjects;
    Scales: IPPSpeedometerScales;
    Scale: IPPSpeedometerScale;
    SolidBrush: IGxSolidBrush;
    Color: IGxColor;
Begin
    MB := MetabaseClass.Active;
    // Get dashboard 
    AdhocReport := MB.ItemById("ADHOC").Edit As IAdhocReport;
    // Get dashboard data sources
    DsObjs := AdhocReport.DataSourceObjects;
    // Get speedometer
    Enalyzer := DsObjs.Item(0).GetSourceObject As IEaxAnalyzer;
    EaxSpeedometer := Enalyzer.Speedometer;
    // Get speedometer parameters
    Speedometer := EaxSpeedometer.Speedometer;
    // Get collection of speedometer scales
    Scales := Speedometer.Scales;
    // Get scale
    Scale := Scales.Item(0);
    // Set up scale border
    Scale.EnableBorder := True;
    // Set up border color
    Color := New GxColor.CreateRGB(255,0,0);
    SolidBrush := New GxSolidBrush.Create(Color);
    Scale.BorderBrush := SolidBrush;
    // Set up border width
    Scale.BorderWidth := 5;
    // Set up style of border rendering
    Scale.BorderStyle := GxDashStyle.Dash;
    // Set up background fill
    Scale.EnableBrush := True;
    // Set up fill color
    Color := New GxColor.CreateRGB(0,255,0);
    SolidBrush := New GxSolidBrush.Create(Color);
    Scale.Background := SolidBrush;
    (Enalyzer As IMetabaseObject).Save;
End Sub UserProc;

After executing the example scale border and background are set up.

See also:

IPPSpeedometerScale