Family property not working?

This is a forum focused on providing support for rTree

Moderators: heatherlaine, kevinmiller, robinmiller, wilstrand

Post Reply
jameshale
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 211
Joined: Thu Sep 04, 2008 6:23 am
Location: Melbourne Australia

Family property not working?

Post by jameshale » Tue Mar 25, 2014 12:43 am

I need to get a list of all nodes under a parent when any of the children nodes are selected.
The Family property seems to promise this
However when I have tried it I only get a single node returned, not the list as described in the notes.
This is regardless of whether I choose a child or even a parent node.
The property syntax I am using is....

"Family_of_node_ID_[x]" where x is the selected node.

Am I doing something wrong or is this a bug?

Btw, any hope you will expand the notes for v2

James

wilstrand
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 114
Joined: Mon Jan 03, 2011 3:02 pm
Contact:

Re: Family property not working?

Post by wilstrand » Tue Mar 25, 2014 8:21 am

Hi James!

If you,
need to get a list of all nodes under a parent when any of the children nodes are selected.
then you have to use the "family" property for the parent of that child node. Like this:

Code: Select all

put the parent_of_node_ID_[x] of grp "rTree" into tParent
get the family_of_node_ID_[tParent] of grp "rTree"
where x is the selected node.

PS. I'm sorry that the notes for V2 are a little thin and I will catch up on that soon.

Best regards
Mats
http:www.tapirsoft.on-rev.com
Open Source LiveCode Plugins - rIDE, rGrid, rTree
LiveCode projects

jameshale
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 211
Joined: Thu Sep 04, 2008 6:23 am
Location: Melbourne Australia

Re: Family property not working?

Post by jameshale » Tue Mar 25, 2014 1:28 pm

Ah Ha.

Thanks Mats, that is what I wanted.

Post Reply

Return to “rTree”