Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Suite Pro
  New Posts New Posts RSS Feed - Draw icon from Picture Box
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Draw icon from Picture Box

 Post Reply Post Reply
Author
Message
AbhishekGoenka View Drop Down
Newbie
Newbie


Joined: 31 March 2008
Status: Offline
Points: 14
Post Options Post Options   Thanks (0) Thanks(0)   Quote AbhishekGoenka Quote  Post ReplyReply Direct Link To This Post Topic: Draw icon from Picture Box
    Posted: 03 April 2008 at 1:11am
Hi

I am using Listview to display Icon and data
My Icon is storing in picture1(16*16)
I am using following code
          LvFiles.IconSize = 16
          LvFiles.Icons.AddIcon Picture1.hWnd, 1, xtpImageNormal
          LvFiles.ListItems.Add , , FileName, 1

this is not woking
where as If I use
LvFiles.Icons.LoadBitmap App.Path & "\AlphaFind.bmp", 1, xtpImageNormal
It works fine

Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 03 April 2008 at 2:59am
Why it have work?
Picture1.hWnd is handle of window not icon.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
AbhishekGoenka View Drop Down
Newbie
Newbie


Joined: 31 March 2008
Status: Offline
Points: 14
Post Options Post Options   Thanks (0) Thanks(0)   Quote AbhishekGoenka Quote  Post ReplyReply Direct Link To This Post Posted: 03 April 2008 at 3:18am
Then how it will work?
if my Icon is stored in PictureBox of size (16*16)
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 03 April 2008 at 4:12am
Hi,
 
Picture1.Picture.Handle
But you must sure it has icon - not bitmap.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
AbhishekGoenka View Drop Down
Newbie
Newbie


Joined: 31 March 2008
Status: Offline
Points: 14
Post Options Post Options   Thanks (0) Thanks(0)   Quote AbhishekGoenka Quote  Post ReplyReply Direct Link To This Post Posted: 03 April 2008 at 4:28am
No it is not working because I think it is bitmap
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.156 seconds.