"QLD_AU" <Ne**@DigitalSn iper.Net> schrieb:
Is their a way in a VB.Net application to set all sub form icons to the
main form ? or even set all icons to the Application icon, without having
to reference the icon as a filename ?
There are different ways to do that:
* You can assign the icon to all forms at designtime.
* You can create a base form that includes the icon and let
all other forms inherit from this base form.
* You can make a reference to the icon or main form available
and assign the icon at runtime, for example, in the forms' constructors:
Providing a reference to an application's main form
<URL:http://dotnet.mvps.org/dotnet/faqs/?id=accessmainf orm&lang=en>
<URL:http://groups.google.d e/groups?selm=Oyz rpoUCFHA.392%40 TK2MSFTNGP14.ph x.gbl>
It's not recommended to assign icons to all forms of an application.
Especially dialogs (forms which are shown modally) typically don't have an
icon at all. Take a look at Microsoft's applications to see when using an
icon in the form's title bar makes sense.
--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://dotnet.mvps.org/dotnet/faqs/>