Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Treeview
Message
From
13/09/2002 03:27:29
Lutz Scheffler
Lutz Scheffler Software Ingenieurbüro
Dresden, Germany
 
 
To
13/09/2002 01:50:06
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Title:
Miscellaneous
Thread ID:
00700045
Message ID:
00700058
Views:
13
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.
*** ActiveX-Steuerelementereignis ***
LPARAMETERS;
 toNode

local;
loNode

IF EMPTY(NODE.Children) THEN
*no Children
 RETURN
ENDIF &&EMPTY(node.Children)

*First Node
loNode         = toNode.CHILD
loNode.Checked = toNode.Checked

*.. until last Node
DO WHILE !loNode=loNode.LastSibling
*Select next child node
 loNode = loNode.NEXT
 loNode.Checked = toNode.Checked
ENDDO &&!loNode=loNode.LastSibling
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.

Off

There is no place like [::1]
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform