Thank you for taking the time to offer me some suggestions about converting
a picture to an icon.
The first suggestion was too simple to work.
I had for a while thought about creating the icon completely in memory and
then allocating it. that seemed rather daunting, so thank you for showing me
an example of how to do it.
Unfortunately - the code creates an icon, and saves it to fil OK BUT
- I cannot use the resultant icon
- the part in the code which draws the icon
( Call DrawIconEx(Picture2.hDC(), 10 , 10 , hIcon, 0, 0, 0, 0,
Call DrawIconEx(Picture2.hDC(), 10 , IconHeight + 20 , hIcon,
0, 0, 0, 0, DI_IMAGE)
Call DrawIconEx(Picture2.hDC(), IconWidth + 20, IconHeight + 20 ,
hIcon, 0, 0, 0, 0, DI_MASK)
doesn't draw anything.
- the icon fili is recognised as an icon - in that I can allocate it to
something on my desk top, but VB will not load it - "invalid format"
also I can't open it say in Corel - "Invalid header".
What is happening - can there be a reason that VB doesn't recognise the
structure of the icon file? I tried a couple of different screen settings to
see if that helped - but it didn't.
If you can't help further, thank you for your rime anyway,