How to get icon from shell32.dll?

N

Neo

I am developing a GUI for a destop application in Visual C++ .Net 2005, I am
trying to create toolbar exactlly same as windows explorer which will have
default windows icons, which are in windows folder shell32.dll.



please let me know, how to get and use icons from shell32.dll?



thanks, best regards,

Mohammad Omer Nasir
 
R

r norman

I am developing a GUI for a destop application in Visual C++ .Net 2005, I am
trying to create toolbar exactlly same as windows explorer which will have
default windows icons, which are in windows folder shell32.dll.



please let me know, how to get and use icons from shell32.dll?

Google reshacker.
 
J

JF Jolin

11 May 2006 18:43:32 +0500 said:
please let me know, how to get and use icons from shell32.dll?

HINSTANCE hDllInst = LoadLibrary("shell32.dll");
HICON hIcon = LoadIcon(hDllInst, MAKEINTRESOURCE( put resource number here ));

The resource number is between 1 and 238 for shell32.dll version 6.0

Use DrawIcon() to draws in the client area of the window.

Use SetClassLong() with GCL_HICON to change an existing window icon.
 
N

Neo

i am trying to set Icon using CToolBar class.
tell me,
how to change toolbar icon using CToolBar class?
how we get explorer toolbar icon and use in our application?

thanks, best regards,

Mohammad Omer Nasir
 
J

JF Jolin

12 May 2006 18:48:12 +0500 said:
i am trying to set Icon using CToolBar class.
tell me,
how to change toolbar icon using CToolBar class?

I am not an MFC user myself.
But as far as I understand them.
I would try or guess around the following:

CImageList::Create CImageList::Add (icon previously found)
CToolBar::GetToolBarCtrl
CToolBarCtrl::SetImageList
how we get explorer toolbar icon and use in our application?

I already answered that question. Didn't I ?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top