method Items.SetParent (Item as HITEM, NewParent as HITEM)

Changes the parent of the given item.

TypeDescription
Item as HITEM A long expression that indicates the handle of the item being moved.
NewParent as HITEM A long expression that indicates the handle of the new parent item.

Use AcceptSetParent property to verify if the the parent of an item can be changed. The following sample shows how to set the parent of first item to second item: Group.Items.SetParent Group.Items(0), Group.Items(1). To retrieve the parent of a given item you can use ItemParent property