Defining Tree Widgets

A tree widget is useful for displaying and maintaining hierarchical information.

The following steps describe how to define a tree widget declaratively. However, you can define more powerful and flexible functionality using ProcScript. For an example, see the Advanced Tree Widget sample.

To define a tree widget:

  1. Specify the initial view to be used. Select Tree View, List View, or both.

    If you choose both views, the widget is split into two panes; the left for the tree view, and the right for the list view. If you choose only one of these views, one pane is displayed for that view.

  2. Specify the properties of the views you selected.
  3. If you choose to use a List View, click Columns to define the labels and formatting for the Details view.

    You can dynamically modify the List View formatting using the Formats and Labels properties in ProcScript. For more information, see Formats and Labels.

  4. Click Types to define the tree item type. For more information, see Type.

    Tree item types define the roles and icons used for items in the tree. You cannot define the structure and contents of the tree widget until you do so.

  5. Optionally, define the drag and drop properties for the tree items before returning to the Define Tree Properties dialog box.

    For more information, see Defining Drag and Drop Behavior for Picture and Tree Widgets.

  6. To determine whether the structure is by numbered level or by unique child-to-parent identifier, set the Build Tree Structure By property. For more information, see Build Tree Structure By.
  7. Click Structure to build the initial tree view structure.

    Add and organize tree items in the structure, using the arrow keys to move items in the hierarchy.

    If you chose Level to build the tree, the identifier is determined by the level number and is incremented automatically as you add and move items. If you chose Child-Parent, enter a unique identifier in the Identifier field.

    For each item, select the Tree Item Type, which is derived from the Types property.

    Note:  The tree view structure can be changed at runtime by building a ValRep list in ProcScript.

  8. Set the other properties as desired.

Related Topics