IMetaAttributesTreeList.GetSelectedNodes

Syntax

GetSelectedNodes: Array;

Description

The GetSelectedNodes method returns an array of the elements selected in the component.

Comments

Each element of the obtained array will contain parameters of the selected tree element described by the IMetaAttributesTreeListNode interface.

Example

Executing the example requires a form with the Button1 button, the MetaAttributesBreadcrumb component, and the MetaAttributesTreeList component named MetaAttributesTreeList1. These components are set up to work with any time series database.

Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Var
    SelNodes: Array;
    MembersSet: IMetaMembersSet;
    Member: IMetaMember;
Begin
    SelNodes := MetaAttributesTreeList1.GetSelectedNodes;
    MembersSet := MetaAttributesTreeList1.GetNodesMembers(SelNodes);
    MembersSet.Reset;
    While Not MembersSet.Eof Do
        Member := MembersSet.Current;
        Debug.WriteLine(Member.Name);
        MembersSet.Next;
    End While;
End Sub Button1OnClick;

Clicking the button displays names of the elements selected in the MetaAttributesTreeList component in the development environment console.

See also:

IMetaAttributesTreeList