Home All Groups Group Topic Archive Search About

Get Icon from CallingAssembly (or ...)

Author
10 Jul 2006 1:59 PM
Pieter
Hi,

I have a Control Library which shows a Form, and i would like to hev the
icon of the CallingAssembly to be shown on this Form. Does anybody knows how
to do this? I can't be able to get this Icon...
Even worse, I don't find how to get it in the application itself :-)

Does anybody has any hints,

Thansk a lot in advance,

Pieter

Author
11 Jul 2006 7:11 AM
M. Posseth
If Me.Owner Is Nothing Then
'set optionally your own icon
            Else
'set icon from the owner
                Me.Icon = Me.Owner.Icon

            End If


Michel Posseth [MCP]





Show quote
"Pieter" wrote:

> Hi,
>
> I have a Control Library which shows a Form, and i would like to hev the
> icon of the CallingAssembly to be shown on this Form. Does anybody knows how
> to do this? I can't be able to get this Icon...
> Even worse, I don't find how to get it in the application itself :-)
>
> Does anybody has any hints,
>
> Thansk a lot in advance,
>
> Pieter
>
>
>
>
Author
11 Jul 2006 9:08 AM
Pieter
Hi,

Thanks for the answer, but it doesn't work. Me.Owner is for the parent Form,
not for the parent assembly..
It's the Application Icon that I need of the application that is calling the
Control Library...
Author
11 Jul 2006 12:58 PM
M. Posseth
Aha ,,, hmmm


well then try

Me.Icon = Drawing.Icon.ExtractAssociatedIcon("path to assembly")

regards

Michel Posseth [MCP]



Show quote
"Pieter" wrote:

> Hi,
>
> Thanks for the answer, but it doesn't work. Me.Owner is for the parent Form,
> not for the parent assembly..
> It's the Application Icon that I need of the application that is calling the
> Control Library...
>
>
>

AddThis Social Bookmark Button