Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Getting the icon of a treeview node
Message
 
To
02/11/2004 15:24:35
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Environment versions
Visual FoxPro:
VFP 6 SP5
OS:
Windows XP SP2
Network:
Windows XP
Miscellaneous
Thread ID:
00957159
Message ID:
00957300
Views:
16
>>Providing the imagelist picture as the same name as the key, and the image file's extensions are the same (BMP or ICO or etc):
>>MyImageList.ListImages.Add(1,[MYIMAGE],LoadPicture("MYIMAGE.BMP"))
>>You can use the picture attribute of the node to get the first name:
>>MyTreeview.Nodes.Add(,1,[Key],[NodeText],[MYIMAGE])
>>The first name would be:
>>lcImageName=MyTreeView.nodes('Key').Image
>>The image file would be:
>>lcImageFile=lcImageName+[.BMP]
>
>
>lcImageName is returning a number not a character.. maybe because I am populating my treeview by index of my imagelist (populated on design mode)

That might be it. I tried a couple of times to get the name of the image file path and name from the image list based on the "key". It kept returning an object. I will check for another way.
Imagination is more important than knowledge
Previous
Reply
Map
View

Click here to load this message in the networking platform