Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Deleting child nodes in a treeview
Message
De
02/05/2001 13:54:22
Héctor Lizarraga
Gobierno Del Edo de Querétaro
Querétaro, Mexique
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Contrôles ActiveX en VFP
Titre:
Deleting child nodes in a treeview
Divers
Thread ID:
00502654
Message ID:
00502654
Vues:
59
Hi all, I have a treeview wich I fill with the routine that comes with the treeview samples. When I delete a node there's no problem but when the node have childrens (If oTreeView.SelectedItem.Children > 0), how can i loop throughout the key's child nodes. I have this:

nIndice = oMenu.SelectedItem.FirstSibling.Index
Do While nIndice <> oMenu.SelectedItem.Node.LastSibling.Index
DELETE FROM DRH_Menu WHERE DRH_Menu.Key = oMenu.Nodes(nIndice).Next.Key
nIndice = oMenu.Nodes(nIndice).Next.Index
Enddo
oMenu.Nodes.Remove(oMenu.SelectedItem.Key)
TABLEUPDATE(0, .T., 'DRH_Menu')

The thing is that deleting the node in the treeview is no problem even with children below it, but i need to match the teeview key's node with my nodes table. How can i do this?

Thanks in advance
Hector L.
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform