hi,
i want to know how to add an image to treeview without using image list ?
thank you.
Printable View
hi,
i want to know how to add an image to treeview without using image list ?
thank you.
I don't think you can!
Why don't you want to use an ImageList?
coz , in my project i use a lot of treeview, and if i use image list , the icon will embeded to image list , so if i compile my project it will produse a large executable file.Quote:
Originally posted by crptcblade
Why don't you want to use an ImageList?
any suggestion ?
You can add the images to the ImageList during run-time.Best regardsVB Code:
ImageList1.ListImages.Add , "UniqueKeyValue", LoadPicture(App.Path & "\ThePic.bmp")
Thats true Joacim, but wouldn't the exe with the images compiled into it still be smaller than shipping the pictures along?
Maybe but the Exe wouldn't take up the same amount of memory when it runs, unless if you'll need to load all images.Quote:
Originally posted by crptcblade
Thats true Joacim, but wouldn't the exe with the images compiled into it still be smaller than shipping the pictures along?
Besides this is what he asked for :)
Its what he asked for, but I was just thinking it might not be the best route. But, oh well, the question got its answer.
:)
It would be a good route to take if you have more then one application that uses the same images.
yeah i use the same images.
and another question :
is compiled project with the size 3,5 MB clasified to big exe file ?
I would say that that's a very big exe file.