maxgui : treeview : list nodes
BlitzMax Forums/BlitzMax Beginners Area/maxgui : treeview : list nodes
| ||
Hi ! i know only 'sibly' node value. How to list all the nodes inside 'sibly' (just children : bplus,bmax, b3d)? -- all i i-- sibly i i- bplus i- bmax i- b3d Thanks |
| ||
TGadget.Kids (TList with TGadgets) Eachin that to get all kids :-) (I would really suggest to use Blide or get HotDocs to be able to use BMs real possibilities ...) |
| ||
Thanks dreamora. agree with you i spend a lot of time to search without success into the doc ;-) |
| ||
No the docs don't mention "internally meant stuff" (ok the don't mention much at all when it comes to OO) although this information definitely is a must have for external usage as well. |
| ||
Draemora could you post an example ? |
| ||
local node:Tgadget = selectedtreeviewnode(someTreeview) for local gadget:Tgadget = eachin node.kids ' do whatever you want ;-) next this should work |
| ||
Thanks Dreamora. Just a mistake into your previous code. This code works :Strict Local win : TGadget =CreateWindow("My Window",40,40,600,400) Local TreeView : TGadget= CreateTreeView (0,0,100,300, win) Local MyRoot:TGadget=TreeViewRoot(Treeview) Local Node1:TGadget = AddTreeViewNode ("node1", MyRoot) Local Node2:TGadget = AddTreeViewNode ("node2", Node1) Local Node3:TGadget = AddTreeViewNode ("node3", Node1) For Local n:TGadget = EachIn Node1.kids Notify n.GetText() Next While True WaitEvent Print CurrentEvent.ToString() Select EventID() Case EVENT_WINDOWCLOSE End End Select Wend |