ExpandItem

Description

Expands a specified item.

Applies to

TreeView controls

Syntax

treeviewname.ExpandItem ( itemhandle )

Argument

Description

treeviewname

The TreeView control in which you want to expand an item

itemhandle

The handle of the item you want to expand

Returns

Integer. Returns 1 if it succeeds and -1 if an error occurs.

Usage

ExpandItem expands only a single item. To expand a specified item including its children, use ExpandAll.

Examples

Example 1

This example expands the current level of a TreeView:

long ll_tvi

ll_tvi = tv_list.FindItem(CurrentTreeItem! , 0)

tv_list.ExpandItem(ll_tvi)

See also