Add image to statusbar panel from imagelist- is it possible?

  • Thread starter Thread starter Thief_
  • Start date Start date
T

Thief_

In VB6, I can use:

StatusBar1.Panels(1).Picture = ImageList1.ListImages(1).Picture

I can't figger out how to do it in VB.Net 2003. I tried converting the
project to .Net and got:

StatusBar1.Panels(1).let_Picture(ImageList1.ListImages(1).Picture)

But that's using the VB6 statusbar & imagelist controls. It doesn't work in
VB.Net statusbar & imagelist controls. Can it be done?
 
Hi,

Dim ico As Icon
Dim ptrIcon As IntPtr

ptrIcon = DirectCast(ImageList1.Images.Item(0), Bitmap).GetHicon
ico = Icon.FromHandle(ptrIcon)
StatusBarPanel1.Icon = ico

StatusBar1.ShowPanels = True

Ken
-------------------
In VB6, I can use:

StatusBar1.Panels(1).Picture = ImageList1.ListImages(1).Picture

I can't figger out how to do it in VB.Net 2003. I tried converting the
project to .Net and got:

StatusBar1.Panels(1).let_Picture(ImageList1.ListImages(1).Picture)

But that's using the VB6 statusbar & imagelist controls. It doesn't work in
VB.Net statusbar & imagelist controls. Can it be done?
 
Back
Top