By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,212 Members | 1,505 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,212 IT Pros & Developers. It's quick & easy.

Accessing fully qualified name of Assembly programmatically?

P: n/a
Hi all,

As per my understanding in order to load an assembly using
Assembly.Load() you have to provide fully qualified name of the
assembly you are trying to load e.g.

asmb=Assembly.Load("System.Windows.Forms,Version=1 .0.5000.0,Culture=neutral,PublicKeyToken=b77a5c561 934e089");

In this case i will have to provide the whole big string in
Assembly.Load() as parameter. Is not there any class/method that would
give me the fully qualified name of the assembly im trying to load so
that i don't have to type the big string. I don't have problems with
typing big strings :). Im just wondering what if i don't the fully
qualified name in advance.

Some restless souls might think what i am trying to acheive here, well
i have used the Reflector tool and im in love with it. I am just trying
to write a program that would load all basic assemblies provided by and then play with them to improve my .net skills in general and
reflection in particular.

So is there any work around ?
Please provide some feedback.

May 19 '06 #1
Share this Question
Share on Google+
1 Reply

P: n/a
Have you tried Assembly.LoadFile() and just pass in the filename?

You could also try calling GetType on an object and then access its
AssemblyQualifiedName property.

string s = MyForm.GetType().AssemblyQualifiedName

May 19 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.