Uninstall Icon

  • Thread starter Thread starter Glyn Meek
  • Start date Start date
G

Glyn Meek

When a program is accessed in the Install/uninstall section of the Control
Panel, it has a small 16x16 icon associated with it. Can anyone tell us how
we specify what that icon should be in our programs? We though we'd got it,
but it keeps defaulting to be the "?" icon usually associated with Help
files.

thanks
 
I learned the hard way that the Visual Studio help is somewhat sketchy,
shall we say, when it comes to how Icons are actually used in .NET
(particularly in WinForms).

The short answer is to make sure that the icon file you have associated with
your Form's "Icon" property actually has all the necessary versions in it,
and that you've edited them to look like something other than the default.
..Ico files, in case you weren't aware, can have multiple versions of the
icon in question embedded in them.

If you are in Visual Studio and you use the Solution explorer's right-click
menu to add an icon to your project, you'll get a blank 32x32 16-color icon.
You can edit it to whatever you want, but unbeknownst to you, there's a
16x16 version hidden in the file that you also have to edit. To get to it,
in the icon editor window right-click anywhere in the blank area outside of
the actual icon bitmap portion. You'll get a context menu that will let you
switch to other versions contained in the same file, and add versions as
well (such as 32x32 256-color, 16x16x256, etc).

Basically, if you associate a .ico file with an "Icon" resource in WinForms,
but the .ico file doesn't have the version (size and color depth) that
WinForms wants to use in some particular context, WinForms has a sequence of
other "fallback" versions that it will also look for. As it happens, the
..ico files you get when you create them in Visual Studio have a default
small-sized icon in them that you also need to edit in order to get what you
want.
 
If you select the project in Solution Explorer and choose Properties (F4),
the top item is AddRemoveProgramsIcon - see if that does it.
 
By the way, I mean your setup & deployment project, not your app project.
--
Phil Wilson
[Microsoft MVP-Windows Installer]
Phil Wilson said:
If you select the project in Solution Explorer and choose Properties (F4),
the top item is AddRemoveProgramsIcon - see if that does it.
--
Phil Wilson
[Microsoft MVP-Windows Installer]
Definitive Guide to Windows Installer
http://apress.com/book/bookDisplay.html?bID=280

Glyn Meek said:
When a program is accessed in the Install/uninstall section of the
Control Panel, it has a small 16x16 icon associated with it. Can anyone
tell us how we specify what that icon should be in our programs? We
though we'd got it, but it keeps defaulting to be the "?" icon usually
associated with Help files.

thanks
 
Back
Top