Hi,
If you check a node's checkbox, Treeviews NodeCheck event will fire. This gives you a reference to the changed Node.
This node owns a property Child wich referenzes the first child node.
Also reference the help (rightclick the treeview and select help)
The following is an untested example.
LPARAMETERS;
toNode
local;
loNode
IF EMPTY(NODE.Children) THEN
RETURN
ENDIF
loNode = toNode.CHILD
loNode.Checked = toNode.Checked
DO WHILE !loNode=loNode.LastSibling
loNode = loNode.NEXT
loNode.Checked = toNode.Checked
ENDDO
HTH
Agnes
>hi all,
>
>i have a treeview in which i have activated it's checkbox property.
>
>when the data is displayed in the treeview, as soon as i check a parent node on the treeview i want that the corresponding child nodes of that parent node also get checked automatically and vise-versa when i uncheck the parent node. i have no idea how to attain this result hence i would be greatful if someone helps me by giving me the code needed.
>
>sincere thanks in advance.
Words are given to man to enable him to conceal his true feelings.
Charles Maurice de Talleyrand-Périgord
Weeks of programming can save you hours of planning.
OffThere is no place like [::1]