469,903 Members | 2,071 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

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

Referencing the Assembly GUID

Hello,

I apologize for such a newbie question, but I'd like to know if there's any
way to reference the assembly GUID?

Thanks!
Mar 1 '06 #1
3 1864
>I apologize for such a newbie question, but I'd like to know if there's any
way to reference the assembly GUID?


What assembly GUID? In .NET v2.0 you can do
yourAssembly.ManifestModule.ModuleVersionId if that's what you're
looking for.
Mattias

--
Mattias Sjögren [C# MVP] mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.
Mar 1 '06 #2
Hi Mattias,

When you create a new Windows Application project, the Assembly.vb has a
GUID, along with author, company name etc. I'm just wondering how to
reference that elsewhere in the program. DOes the
yourAssembly.ManifestModule.ModuleVersionID do the same thing?
"Mattias Sjögren" <ma********************@mvps.org> wrote in message
news:uJ*************@TK2MSFTNGP15.phx.gbl...
I apologize for such a newbie question, but I'd like to know if there's
any
way to reference the assembly GUID?


What assembly GUID? In .NET v2.0 you can do
yourAssembly.ManifestModule.ModuleVersionId if that's what you're
looking for.
Mattias

--
Mattias Sjögren [C# MVP] mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.

Mar 1 '06 #3
>When you create a new Windows Application project, the Assembly.vb has a
GUID, along with author, company name etc. I'm just wondering how to
reference that elsewhere in the program.


You can get it with
yourAssembly.GetCustomAttributes(GetType(GuidAttri bute)) or
Marshal.GetTypeLibGuidForAssembly(yourAssembly).
Mattias

--
Mattias Sjögren [C# MVP] mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.
Mar 1 '06 #4

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

5 posts views Thread by Tamir Khason | last post: by
14 posts views Thread by Nak | last post: by
1 post views Thread by Brian Henry | last post: by
3 posts views Thread by pranesh.nayak | last post: by
2 posts views Thread by Rob R. Ainscough | last post: by
5 posts views Thread by Jim | last post: by
1 post views Thread by Waqarahmed | last post: by
reply views Thread by Salome Sato | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.