TreeGetCurItemProperty method (WinStudio scripts)

Applies To

IWSFormComponent interface, tree objects

Definition

Returns a string containing the value of a property in the current node of a tree component.

Syntax

object.TreeGetCurItemProperty( integer )

object.TreeGetCurItemProperty( string )

  Part   Description
object Required. A reference to a valid tree component object.
integer Optional. The property in a zero-based index found at the target node. Properties are counted from left to right as they appear in the data-binding specifications in WinStudio.
string Optional. The name of the property found at the target node.

Remarks

Both hidden properties and displayed properties are indexed and are accessible by this method. An out-of-range index number returns an empty string.

Example

Sub Main()
    Dim intIndex As Integer
    Dim strProp As String
    'Set the index to retrieve the third property in a node.
    intIndex = 2
    'Get the text of the third property in the current node.
    strProp = ThisForm.Components("OrdersTree").TreeGetCurItemProperty(intIndex)
    Application.ShowMessage(strProp)
End Sub

Related Topics

About Tree components

Adding a Tree component

TreeGetCurItemLevelProperty method

TreeGetCurLevel method

TreeRefresh method

TreeSetCacheRecordCap method