IPPSpeedometer.BorderWidth

Fore Syntax

BorderWidth: Double;

Fore.NET Syntax

BorderWidth: double;

Description

The BorderWidth property determines width of speedometer area border.

Comments

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

Fore 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;
    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;
    // Set up parameters of speedometer area border
    Speedometer.EnableBorder := True;
    Speedometer.BorderWidth := 10;
    Speedometer.BorderStyle := GxDashStyle.Dot;
    // Set up color speedometer area border
    Color := New GxColor.CreateRGB(255,0,0);
    SolidBrush := New GxSolidBrush.Create(Color);
    Speedometer.BorderBrush := SolidBrush;
    (Enalyzer As IMetabaseObject).Save;
End Sub UserProc;

After executing the example the speedometer area border is added. Border line width, style and color are set up.

Fore.NET Example

The requirements and result of the Fore.NET example execution match with those in the Fore example.

Imports Prognoz.Platform.Interop.Metabase;
Imports Prognoz.Platform.Interop.AdHoc;
Imports Prognoz.Platform.Interop.Express;
Imports Prognoz.Platform.Interop.Speedometer;
Imports Prognoz.Platform.Interop.Drawing;

Public Shared Sub Main(Params: StartParams);
Var
    Speedometer: IPPSpeedometer;
    MB: IMetabase;
    AdhocReport: IAdhocReport;
    EaxSpeedometer: IEaxSpeedometer;
    Enalyzer: IEaxAnalyzer;
    DsObjs: IAdhocDataSourceObjects;
    SolidBrush: GxSolidBrushClass;
    Color: GxColorClass;
    BorderColor: GxColor;
Begin
    MB := Params.Metabase;
    // 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;
    // Set up parameters of speedometer area border
    Speedometer.EnableBorder := True;
    Speedometer.BorderWidth := 10;
    Speedometer.BorderStyle := GxDashStyle.gdsDot;
    // Set up color speedometer area border
    Color := New GxColorClassClass();
    BorderColor := Color.FromKnownColor(GxKnownColor.clRed);
    SolidBrush := New GxSolidBrushClass();
    SolidBrush.Color := BorderColor;
    Speedometer.BorderBrush := SolidBrush;
    (Enalyzer As IMetabaseObject).Save();
End Sub;

See also:

IPPSpeedometer