IMetaAttributesBreadcrumb.ExtendedRootItem

Fore Syntax

ExtendedRootItem: Boolean;

Fore.NET Syntax

ExtendedRootItem: Boolean;

Description

The ExtendedRootItem property determines whether the combined element is displayed in the component.

Comments

If the property is set to True, a combined element is displayed. The combined element includes a button for clearing the breadcrumb and an additional button with the text determined in the RootText property. The RootHint property may be used to set the text of a tooltip for additional button. Clicking the additional button generates the OnRootClick event for the component.

Example

Executing the example requires a form, the MetaAttributesBreadcrumb component on the form and named MetaAttributesBreadcrumb1 and the MetabaseOpenDialog component named MetabaseOpenDialog1. The filter that is used to select only time series databases is specified for the MetabaseOpenDialog1 component. The repository must contain a time series database with the FC identifier.

Class TESTForm: Form
    MetaAttributesBreadcrumb1: MetaAttributesBreadcrumb;
    MetabaseOpenDialog1: MetabaseOpenDialog;

    Sub TESTFormOnCreate(Sender: Object; Args: IEventArgs);
    Var
        MB: IMetabase;
        MDesc: IMetabaseObjectDescriptor;
    Begin
        MB := MetabaseClass.Active;
        MDesc := MB.ItemById("FC");
        MetaAttributesBreadcrumb1.Rubricator := MDesc.Open(NullAs IRubricatorInstance;
        MetaAttributesBreadcrumb1.ExtendedRootItem := True;
        MetaAttributesBreadcrumb1.RootText := Base: + MDesc.Name;
        MetaAttributesBreadcrumb1.RootHint := MDesc.Name;
    End Sub TESTFormOnCreate;

    Sub MetaAttributesBreadcrumb1OnRootClick(Sender: Object; Args: IBreadcrumbItemEventArgs);
    Var
        MDesc: IMetabaseObjectDescriptor;
    Begin
        If MetabaseOpenDialog1.Execute(Self) Then
            MDesc := MetabaseOpenDialog1.Object;
            MetaAttributesBreadcrumb1.Rubricator := MDesc.Open(NullAs IRubricatorInstance;
            MetaAttributesBreadcrumb1.RootText := Base: + MDesc.Name;
            MetaAttributesBreadcrumb1.RootHint := MDesc.Name;
        End If;
    End Sub MetaAttributesBreadcrumb1OnRootClick;

End Class TESTForm;

The MetaAttributesBreadcrumb1 component is connected to the specified time series database when the form is launched. The root element is also displayed in the component. The name of time series database is specified in the text of the element. The dialog box for selection of time series database from repository appears on clicking the root element. The selected database is linked to the MetaAttributesBreadcrumb1 component.

Fore.NET Example

Executing the example requires a form, the MetaAttributesBreadcrumbNet component named MetaAttributesBreadcrumbNet1 positioned on this form and the MetabaseOpenDialogNet component named MetabaseOpenDialogNet1. The filter that is used to select only time series databases is specified for the MetabaseOpenDialogNet1 component. The repository must contain a time series database with the FC identifier.

Imports Prognoz.Platform.Forms.Net;
Imports Prognoz.Platform.Interop.Cubes;
Imports Prognoz.Platform.Interop.Metabase;

Public Partial Class TESTForm: Prognoz.Platform.Forms.Net.ForeNetForm
    Public Constructor TESTForm();
    Begin
        InitializeComponent();
    End Constructor;

    Private Sub TESTForm_Load(sender: System.Object; e: System.EventArgs);
    Var
        MDesc: IMetabaseObjectDescriptor;
    Begin
        MDesc := Self.Metabase.ItemById["FC"];
        MetaAttributesBreadcrumbNet1.Rubricator := MDesc.Open(NullAs IRubricatorInstance;
        MetaAttributesBreadcrumbNet1.ExtendedRootItem := true;
        MetaAttributesBreadcrumbNet1.RootText := Base: + MDesc.Name;
        MetaAttributesBreadcrumbNet1.RootHint := MDesc.Name;
    End Sub;

    Private Sub metaAttributesBreadcrumbNet1_OnRootClick(Sender: System.Object; Args: Prognoz.Platform.Interop.Forms.EventArgs);
    Var
        MDesc: IMetabaseObjectDescriptor;
    Begin
        If MetabaseOpenDialogNet1.Execute(Self) Then
            MDesc := MetabaseOpenDialogNet1.Object;
            MetaAttributesBreadcrumbNet1.Rubricator := MDesc.Open(NullAs IRubricatorInstance;
            MetaAttributesBreadcrumbNet1.RootText := Base: + MDesc.Name;
            MetaAttributesBreadcrumbNet1.RootHint := MDesc.Name;
        End If;
    End Sub;

End Class;

The MetaAttributesBreadcrumbNet1 component is connected to the specified time series database when the form is launched. The root element is also displayed in the component. The name of time series database is specified in the text of the element. The dialog box for selection of time series database from repository appears on clicking the root element. The selected database is linked to the MetaAttributesBreadcrumbNet1 component.

See also:

IMetaAttributesBreadcrumb | IMetaAttributesBreadcrumb.RootText | IMetaAttributesBreadcrumb.RootHint