#Define tvwFirst 0 #Define tvwLast 1 #Define tvwNext 2 #Define tvwPrevious 3 #Define tvwChild 4 oForm = Createobject('myForm') With oForm With .Tree .Left = 10 .Top = 10 .Width = 200 .Height = 200 .Nodes.Add(,tvwFirst,"root0",'Main node 0') .Nodes.Add(,tvwFirst,"root1",'Main node 1') .Nodes.Add(,tvwFirst,"root2",'Main node 2') * Add 2 child nodes to root1 .Nodes.Add('root1',tvwChild,"child11",'Child11') .Nodes.Add('root1',tvwChild,"child12",'Child12') *Add a child node to root2 .Nodes.Add('root2',tvwChild,"child23",'Child23') .Nodes.Add('child11',tvwChild,"child113",'child113') With .Nodes.Add('child113',tvwPrevious,"child112",'child112') .Bold=.T. Endwith With .Nodes.Add('child112',tvwPrevious,"child111",'child111') .Bold = .T. Endwith * Later decided to add another 2 nodes to root2 * Place first before child23 With .Nodes.Add('child23',tvwPrevious,"child22",'Child22') .Bold=.T. Endwith * Place next before child22 With .Nodes.Add('child22',tvwPrevious,"child21",'Child21') .Bold=.T. Endwith For Each oNode In .Nodes && Expand all nodes for easy view oNode.Expanded = .T. Endfor Endwith .Show() Endwith Read Events Define Class myForm As Form ADD OBJECT Tree as OleControl WITH ; Name = 'Tree',OleClass='MSComCtlLib.TreeCtrl' PROCEDURE init With This.tree .linestyle = 1 .Font.Name = 'Times New Roman' .Font.Size = 10 .indentation = 5 Endwith endproc Procedure QueryUnload Clear Events Endproc EnddefineFor a quick load (actually no load but load on demand) and some other TV processing check UT magazine first issue (June 2001?).