Sign in to follow this  
booom

Loading a Icon in c++

Recommended Posts

I think I no what it is, if it is what runs the code you type on the program. I use Dev-C++ it is free.

Share this post


Link to post
Share on other sites
Free but old, you should grab Visual Studio 2008 Express here http://www.microsoft.com/express/ it's free too. Or you can try Code::Blocks http://www.codeblocks.org/ some people here seems to recommend it.

Share this post


Link to post
Share on other sites
A windows app with a single main window typically has two icons: one that is associated with the window and displayed in the upper left corner, and one that is read by the shell and used as the icon in Explorer and in the taskbar. The first you associate with the window class when you call RegisterClassEx by specifying a handle to your icon. You obtain this handle by calling LoadImage and specifying either the resource or filename of your icon. The second gets associated "automatically", all you have to do is make it the first icon resource in your application. I don't remember if Dev-C++ has a resource editor or not (it's been a long time), but you really should be using Visual Studio anyway at this point if you're doing any serious Windows programming.

Your shell icon also need to have different sizes built in, typically you need 16x16, 32x32, and 48x48. XP supports 32-bit icons with alpha channel, but for previous versions you'll need to supply low-color versions as well. Vista also supports a 256x256 icon size with PNG compression.

Share this post


Link to post
Share on other sites
Thank you for your help every one. ANd I found out that you can just add it by the program.

[Edited by - booom on March 24, 2008 3:46:09 PM]

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this