Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Getting child nodes of a treeview
Message
De
30/11/2006 19:13:03
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
Getting child nodes of a treeview
Versions des environnements
Visual FoxPro:
VFP 6
Divers
Thread ID:
01173946
Message ID:
01173946
Vues:
44
Now that I'm able to get the child nodes of a parent node or selected node, I'd like now to get the child nodes of these child nodes and append it to a table.

My current code is this
nodeptr = thisform.oletreeview.selecteditem

local childnodeptr
childnodeptr = m.nodeptr.child

select ckey from treeview into cursor csrtemp where alltrim(ckey)==nodeptr.key
use (dbf([csrtemp])) again in 0 alias csrtable
select csrtable
use in csrtemp

do while !isnull(m.childnodeptr)
	append blank
	replace ckey with m.childnodeptr.key
	childnodeptr = m.childnodeptr.next
enddo
I want my table to look like this,

Selected node
Child 1 of selected node
Child 1.1
Child 1.2
Child 1.2.1
Child 1.2.2
Child 1.3
Child 2 of selected node
Child 2.1
Child 2.1.1
Child 3 of selected node
Child 3.1
Child 3.2

Any one help me?
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform