-
1 Attachment(s)
Delphi 7 > Treeview help
Last thread....promise:D
Ok, ive assigned a TImagelist which contains 3 images. (Index 0,1,2) to a TTreeview. The screenshot shown gives you an idea of what im doing.
I have managed to get the correct picture of the root node, and the sub one. If you notice on the root node, the icon is a closed folder. What i want, is to determine if the root node is open (showing sub items), and if so i want to change the closed folder to open a folder.
Index 0 = Closed folder
Index 1 = Open folder
-
And also, how to count how many sub items there are in a Treeview, and display the number in a Statusbar:cool:
-
1) Could you check the current image of the node - and if its open, then you know its open ....
2) Use a recursive algorithm :)
-
1) thanks for the reply
2) I can get it to change when the node is open, but cant change the image back when its closed
3) Dont knw how, simply put
4) Make a delphi forum, and it will keep the chit-chat people happy:bigyello:
-
And how to use a TEdit textbox to search through each node to find a match?
U here Corona:(
EDIT: Alternatively, does anoybody know how to do this in VB? If so, please share code and ill try converting it to Delphi :D