Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Add picture to tree
Message
 
 
À
13/02/2001 06:31:59
Information générale
Forum:
Visual FoxPro
Catégorie:
Contrôles ActiveX en VFP
Divers
Thread ID:
00475208
Message ID:
00475361
Vues:
25
>I am using mscomctlib.treecrtl and mscomctlib.ImagelistCtl
>
>It is working but i want to add an image to the tree on runtime.
>
>how can help me
>
>Kind Regards
>
>
>Jan Dorresteijn

You can use the ListImages.Add method to add as many images you want at run-time.

Ex.
Imagelist.ListImages.Add(,'imagekey',LoadPicture('newimage.bmp'))

Once bound, all images will be displayed using the ImageHeight and ImageWidth properties. They are read-only but you can still add images all you want. When you add nodes to the Treeview, just use the indexkey of the new images.

Treeview.Nodes.Add(,TVWCHILD,'nodekey','Display Text','imagekey')

HTH.
Larry Miller
MCSD
LWMiller3@verizon.net

Accumulate learning by study, understand what you learn by questioning. -- Mingjiao
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform