IMapLayerArrows.ToolTipFormat

Fore Syntax

ToolTipFormat: String;

Fore.NET Syntax

ToolTipFormat: string;

Description

The ToolTipFormat property determines format of a tooltip for arrows.

Comments

To refresh data of the arrows collection on the map, use IMapLayerArrows.RefreshData.

Fore Example

Executing the example requires a regular report with the REPORT identifier containing a map with arrows.

Add links to the Map, Metabase, Report system assemblies.

Sub UserProc;
Var
    MB: IMetabase;
    Report: IPrxReport;
    Map: IMap;
    Layer: IMapLayer;
    L_Arrows: IMapLayerArrows;
    Arrow: IMapArrow;
Begin
    // Get repository
    MB := MetabaseClass.Active;
    // Get regular report
    Report := MB.ItemById("REPORT").Edit As IPrxReport;
    // Get map
    Map := (Report.ActiveSheet As IPrxTable).TabSheet.Objects.Item(0).Extension As IMap;
    // Get map layer
    Layer := Map.Layers.Item(0);
    // Get layer with arrows on map
    L_Arrows := Layer.Arrows;
    // Use data mapping and display to the console mapping attributes
    L_Arrows.UseDataMapping := True;
    Debug.WriteLine("Name of the attribute containing parameters of arrows size - " + L_Arrows.BasementWidth.AttributeName);
    Debug.WriteLine("Name of the attribute containing parameters of arrows color - " + L_Arrows.ColorMapping.AttributeName);
    L_Arrows.ToolTipFormat := "# ##0,00";
    // Refresh layer with arrows
    L_Arrows.RefreshData;
    // Get arrow
    Arrow := L_Arrows.Item(0);
    // Change arrow identifier
    Arrow.Id := "MapArrowId";
    // Display to the console
    Debug.WriteLine("Name of the attribute containing parameters of arrow size - " + Arrow.BasementWidth.AttributeName);
    Debug.WriteLine("Name of the attribute containing parameters of arrow color - " + Arrow.ColorMapping.AttributeName);
    // Save changes
    (Report As IMetabaseObject).Save;
End Sub UserProc;

After executing the example format of tooltips for arrows will be changed, identifier of the specified arrow will be changed. The console window displays names of attributes containing arrow size and color parameters.

Fore.NET Example

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

Imports Prognoz.Platform.Interop.Map;
Imports Prognoz.Platform.Interop.Report;

Public Shared Sub Main(Params: StartParams);
Var
    MB: IMetabase;
    Report: IPrxReport;
    Map: IMap;
    Layer: IMapLayer;
    L_Arrows: IMapLayerArrows;
    Arrow: IMapArrow;
Begin
    // Get repository
    MB := Params.Metabase;
    // Get regular report
    Report := MB.ItemById["REPORT"].Edit() As IPrxReport;
    // Get map
    Map := (Report.ActiveSheet As IPrxTable).TabSheet.Objects.Item[0].Extension As IMap;
    // Get map layer
    Layer := Map.Layers.Item[0];
    // Get layer with arrows on map
    L_Arrows := Layer.Arrows;
    // Use data mapping and display to the console mapping attributes
    L_Arrows.UseDataMapping := True;
    System.Diagnostics.Debug.WriteLine
    ("Name of the attribute containing parameters of arrows size - " + L_Arrows.BasementWidth.AttributeName);
    System.Diagnostics.Debug.WriteLine
    ("Name of the attribute containing parameters of arrows color - " + L_Arrows.ColorMapping.AttributeName);
    L_Arrows.ToolTipFormat := "# ##0,00";
    // Refresh layer with arrows
    L_Arrows.RefreshData();
    // Get arrow
    Arrow := L_Arrows.Item(0);
    // Change arrow identifier
    Arrow.Id := "MapArrowId";
    // Display to the console
    System.Diagnostics.Debug.WriteLine
    ("Name of the attribute containing parameters of arrow size - " + Arrow.BasementWidth.AttributeName);
    System.Diagnostics.Debug.WriteLine
    ("Name of the attribute containing parameters of arrow color - " + Arrow.ColorMapping.AttributeName);
    // Save changes
    (Report As IMetabaseObject).Save();
End Sub;

See also:

IMapLayerArrows