So I decided it was time to add some images to my treeview nodes, and why did I so stupidly think that was going to be something easy?
I've read about everything posted here, including the links to Doug Hennig's "Mother of all treeviews", but I am still not getting it for some reason. Doug's thing in my case I think it "too much". I just want something to show some images on my control, so please don't direct me back to his papers, I've read them, and played with his controls and still can't get it to work in my own forms (and for my liking it drags along too many other stuff that I won't ever use, and yes I could remove those parts, but then it starts to get very twitchy.
So fundamentally here is what I don't get. Following one of Mike Lewis's suggestions (from a post in like 2012), I made a container (TreeViewContainer), and I put two ActiveX controls into that Microsoft Treeview Control 6.0 and Microsoft ImageList Control 6.0 (I figured those sounded safely compatible).
One thing that perplexes me is, how does MS ImageList control EVER get populated? All the examples I see, (like in Sample) makes one reference to the world "world" which is clearly the icon it uses, but I can find nowhere in the code (not the form, not the objects, not the non-visual classes) that reference loading that image to the listview. It just starts getting "Used" but if I do that, and reference my images, of course, nothing is there.
The second odd part is how exactly does the image in the node get referenced? I see references to Objects in Doug's example that just don't make sense to me, because again I can find nowhere were those objects get created.
[rant] I have the tree working fine for loading the nodes otherwise. By Text, and giving them keys, everything is just as I want it, I just want to put the <expletive> icon in front of the nodes! [/endrant]
Best Regards,
Scott
MIET, MASHRAE, CDCP, CDCS, CDCE, CTDC, CTIA, ATS
"Everything should be made as simple as possible, and no simpler."
I've read about everything posted here, including the links to Doug Hennig's "Mother of all treeviews", but I am still not getting it for some reason. Doug's thing in my case I think it "too much". I just want something to show some images on my control, so please don't direct me back to his papers, I've read them, and played with his controls and still can't get it to work in my own forms (and for my liking it drags along too many other stuff that I won't ever use, and yes I could remove those parts, but then it starts to get very twitchy.
So fundamentally here is what I don't get. Following one of Mike Lewis's suggestions (from a post in like 2012), I made a container (TreeViewContainer), and I put two ActiveX controls into that Microsoft Treeview Control 6.0 and Microsoft ImageList Control 6.0 (I figured those sounded safely compatible).
One thing that perplexes me is, how does MS ImageList control EVER get populated? All the examples I see, (like in Sample) makes one reference to the world "world" which is clearly the icon it uses, but I can find nowhere in the code (not the form, not the objects, not the non-visual classes) that reference loading that image to the listview. It just starts getting "Used" but if I do that, and reference my images, of course, nothing is there.
The second odd part is how exactly does the image in the node get referenced? I see references to Objects in Doug's example that just don't make sense to me, because again I can find nowhere were those objects get created.
[rant] I have the tree working fine for loading the nodes otherwise. By Text, and giving them keys, everything is just as I want it, I just want to put the <expletive> icon in front of the nodes! [/endrant]
Best Regards,
Scott
MIET, MASHRAE, CDCP, CDCS, CDCE, CTDC, CTIA, ATS
"Everything should be made as simple as possible, and no simpler."