ExpandAllChildren method (DataWindows)
Description
Expands a group in a TreeView DataWindow that has the specified TreeView
level and includes the specified row; also expands all the group’s
children.
Controls
DataWindow type |
Method applies to |
---|---|
PowerBuilder |
DataWindow control |
Syntax
[PowerBuilder]
1 |
<span>Integer <span>dw_control</span>.ExpandAllChildren</span>(long <span>row</span>, long <span>groupLevel</span>) |
Argument |
Description |
---|---|
dw_control |
A reference to a TreeView-style DataWindow |
row |
The number of the row that belongs to |
groupLevel |
The TreeView level of the group to be |
Return Values
Returns 1 if the expand operation succeeds and one of the
following negative values if it fails:
-
-1
DataWindow is null
-
-5
One or more of the parameters are invalid
-
-16
DataWindow is not a TreeView DataWindow
Usage
A TreeView DataWindow has several TreeView level bands (groups)
that can be expanded and collapsed. You can use the ExpandAllChildren method to
expand a group with a specified TreeView level in a TreeView DataWindow
and all of its children.
The ExpandAllChildren method triggers the
Expanding and Expanded events.
Examples
The following example expands the group in a TreeView
DataWindow that has TreeView level 2 and includes row 3; it also
expands all the group’s children:
1 |
integer li_ret<br>li_ret = dw_treeview.<span>ExpandAllChildren</span>(3,2) |