468,535 Members | 1,540 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 468,535 developers. It's quick & easy.

Questions about form icons in WinForms apps

Hi,

- Is there a way to that every form in my app use the same icon withouth
adding it to the Icon property one form by one ?

- Do I must add to my app the icon(s) I will use in my forms as embedded
resource, then I must use the assembly.GetManifestResourceStream in order to
assign to my forms ? Is that the correct way ?

- Can I use 24 bit icons ?

Regards
Luis Arvayo
Mar 8 '06 #1
5 2096
Luis,

You should be able to use 24 bit icons if you are using Windows XP (I
believe it is an OS-dependent feature).

As for an easy way to solve this, create a class that derives from Form,
and set the icon in the constructor.

Then, have all of your classes derive from that new Form type that you
have defined, and it should work fine.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Luis Arvayo" <am**********@prodigy.net.mx> wrote in message
news:uz**************@TK2MSFTNGP11.phx.gbl...
Hi,

- Is there a way to that every form in my app use the same icon withouth
adding it to the Icon property one form by one ?

- Do I must add to my app the icon(s) I will use in my forms as embedded
resource, then I must use the assembly.GetManifestResourceStream in order
to assign to my forms ? Is that the correct way ?

- Can I use 24 bit icons ?

Regards
Luis Arvayo

Mar 8 '06 #2
Hello Luis,

I found the idea to have icons for all forms not very good, cuz there are
dialogs that don't have icons at all (modals one).

LA> - Is there a way to that every form in my app use the same icon
LA> withouth adding it to the Icon property one form by one ?
LA>
LA> - Do I must add to my app the icon(s) I will use in my forms as
LA> embedded resource, then I must use the
LA> assembly.GetManifestResourceStream in order to assign to my forms ?
LA> Is that the correct way ?
LA>
LA> - Can I use 24 bit icons ?
LA>
LA> Regards
LA> Luis Arvayo
---
WBR,
Michael Nemtsev :: blog: http://spaces.msn.com/laflour

"At times one remains faithful to a cause only because its opponents do not
cease to be insipid." (c) Friedrich Nietzsche
Mar 8 '06 #3
Thank you. That gave me a good hint to what to do.

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.com> escribió
en el mensaje news:O5**************@TK2MSFTNGP10.phx.gbl...
Luis,

You should be able to use 24 bit icons if you are using Windows XP (I
believe it is an OS-dependent feature).

As for an easy way to solve this, create a class that derives from
Form, and set the icon in the constructor.

Then, have all of your classes derive from that new Form type that you
have defined, and it should work fine.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Luis Arvayo" <am**********@prodigy.net.mx> wrote in message
news:uz**************@TK2MSFTNGP11.phx.gbl...
Hi,

- Is there a way to that every form in my app use the same icon withouth
adding it to the Icon property one form by one ?

- Do I must add to my app the icon(s) I will use in my forms as embedded
resource, then I must use the assembly.GetManifestResourceStream in order
to assign to my forms ? Is that the correct way ?

- Can I use 24 bit icons ?

Regards
Luis Arvayo


Mar 8 '06 #4
But the icon of that form will be seen anyway in the windows main toolbar

"Michael Nemtsev" <ne*****@msn.com> escribió en el mensaje
news:9c**************************@msnews.microsoft .com...
Hello Luis,

I found the idea to have icons for all forms not very good, cuz there are
dialogs that don't have icons at all (modals one).

LA> - Is there a way to that every form in my app use the same icon
LA> withouth adding it to the Icon property one form by one ?
LA> LA> - Do I must add to my app the icon(s) I will use in my forms as
LA> embedded resource, then I must use the
LA> assembly.GetManifestResourceStream in order to assign to my forms ?
LA> Is that the correct way ?
LA> LA> - Can I use 24 bit icons ?
LA> LA> Regards
LA> Luis Arvayo
---
WBR,
Michael Nemtsev :: blog: http://spaces.msn.com/laflour

"At times one remains faithful to a cause only because its opponents do
not cease to be insipid." (c) Friedrich Nietzsche

Mar 8 '06 #5
Hello Luis,

modal dialog boxed are not showed there, and *generally* have no icons.
But it's up to u whether create icons for all windows or not. I've seen a
lot of samples where dialog boxes were with icons

LA> But the icon of that form will be seen anyway in the windows main
LA> toolbar
LA>
LA> "Michael Nemtsev" <ne*****@msn.com> escribió en el mensaje
LA> news:9c**************************@msnews.microsoft .com...
LA>
Hello Luis,

I found the idea to have icons for all forms not very good, cuz there
are dialogs that don't have icons at all (modals one).

LA> - Is there a way to that every form in my app use the same icon
LA> withouth adding it to the Icon property one form by one ?
LA> LA> - Do I must add to my app the icon(s) I will use in my forms
as
LA> embedded resource, then I must use the
LA> assembly.GetManifestResourceStream in order to assign to my forms
?
LA> Is that the correct way ?
LA> LA> - Can I use 24 bit icons ?
LA> LA> Regards
LA> Luis Arvayo
---
WBR,
Michael Nemtsev :: blog: http://spaces.msn.com/laflour
"At times one remains faithful to a cause only because its opponents
do not cease to be insipid." (c) Friedrich Nietzsche

---
WBR,
Michael Nemtsev :: blog: http://spaces.msn.com/laflour

"At times one remains faithful to a cause only because its opponents do not
cease to be insipid." (c) Friedrich Nietzsche
Mar 9 '06 #6

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

8 posts views Thread by Beatrice Rutger | last post: by
14 posts views Thread by shamirza | last post: by
10 posts views Thread by Jules Winfield | last post: by
2 posts views Thread by Eric B. | last post: by
reply views Thread by Derek Hart | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.