Hi Thomas,
Thanks for your help, the GUID that I am after is actually the one that is
exposed to COM, if you take a look in the AssemblyInfo.vb file you will see
the lines,
'The following GUID is for the ID of the typelib if this project is exposed
to COM
<Assembly: Guid(" GUID goes in here ")>
I am after getting this GUID programatically. I thought it might be in the
application object, as is everything else that is in the Assembly file but
it isn't. I want to use it for making toolbar and menu buttons for Internet
Explorer, and for this you need to provide a GUID. I didn't want to just
use a randomly generated GUID just incase it had been used perviously
(though I am not sure of the chances of this happening are). So I thought
if I use my applications GUID this would solve all problems. I'm short of
copying an pasting but I don't like canning things like that.
Thanks for your help though, any ideas on the above?
Nick.
--
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
Slow internet connection?
Having problems with you job?
You're marriage is on the rocks?
You can't sleep at night?
You have a drink and drugs addiction?
You are sexually impotent?
Then enable Option Strict!
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
"Thomas" <no****@nospam.nospam> wrote in message
news:uy**************@tk2msftngp13.phx.gbl...
Hi Nick,
you can get most Assembly info from the System.Reflection namespace.
You get the current domain from the AppDomain type, then get the list of
assemblies from it. When you find the assembly that you are looking for
(the list contains all the system assemblies as well), check the referenced
assemblies for that one assembly - the referenced assembly is of type
AssemblyName, and you can get a load of info from that. I'm not sure about
the GUID, but it as a PublicKeyToken property, which may be what you are
looking for....
Here's some code to get you started:
Dim ad As AppDomain
Dim ass As System.Reflection.Assembly
Dim add() As System.Reflection.Assembly = ad.CurrentDomain.GetAssemblies()
Dim addRef() As System.Reflection.AssemblyName
Dim addRefItem As System.Reflection.AssemblyName
For Each ass In add
If ass.ToString.Substring(0, 5).ToUpper = "THE APP NAME" Then
addRef = ass.GetReferencedAssemblies
For Each addRefItem In addRef
Next
Next
"Nak" <a@a.com> wrote in message
news:Or**************@tk2msftngp13.phx.gbl... Hi there,
Does anyone know how I would get the value of the assembly GUID in
code from within the same application? Thanks in advance.
Nick.
--
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
Slow internet connection?
Having problems with you job?
You're marriage is on the rocks?
You can't sleep at night?
You have a drink and drugs addiction?
You are sexually impotent?
Then enable Option Strict!
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\