Connection Information

To perform the requested action, WordPress needs to access your web server. Please enter your FTP credentials to proceed. If you do not remember your credentials, you should contact your web host.

Connection Type

Syntax 5: For TreeView controls – PB Docs 2022 – PowerBuilder Library

Syntax 5: For TreeView controls – PB Docs 2022

Syntax 5: For TreeView controls

Description

Inserts an item at a specific level and order in a TreeView
control.

Applies to

TreeView controls

Syntax

Argument

Description

treeviewname

The name of the TreeView control in which you want to
insert an item.

handleparent

The handle of the item one level above the item you want
to insert. To insert an item at the first level, specify
0.

handleafter

The handle of the item on the same level that you will
insert the item immediately after.

label

The label of the item you are inserting.

pictureindex

The Index of the index of the picture you are adding to
the image list.

Return value

Long.

Returns the handle of the inserted item if it succeeds and -1 if
an error occurs.

Usage

Use this syntax to set just the label and picture index. Use the
next syntax if you need to set additional properties for the
item.

If the TreeView’s SortType property is set to a value other than
Unsorted!, the inserted item is sorted with its siblings.

If you are inserting the first child of an item, use
InsertItemLast or InsertItemFirst instead. Those functions do not
require a handleafter value.

Examples

This example inserts a TreeView item that is on the same level as
the current TreeView item. It uses FindItem to get the current item and
its parent, then inserts the new item beneath the parent item:

See also

GetItem


Document get from Powerbuilder help
Thank you for watching.
Was this article helpful?
Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x