Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / Managed C++ / May 2006

Tip: Looking for answers? Try searching our database.

How to get icon from shell32.dll?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Neo - 11 May 2006 14:43 GMT
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 norman - 11 May 2006 14:54 GMT
>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.
JF Jolin - 11 May 2006 21:08 GMT
> 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.
Neo - 12 May 2006 14:48 GMT
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

> > please let me know, how to get and use icons from shell32.dll?
>
[quoted text clipped - 6 lines]
>
> Use SetClassLong() with GCL_HICON to change an existing window icon.
JF Jolin - 12 May 2006 18:52 GMT
> 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 ?

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.