System.Type.Type()

  • Thread starter Thread starter Robert Towne
  • Start date Start date
R

Robert Towne

What happens if I pass the assembly-qualified name of some type to
"System.Type.GetType()" where the name I pass originates from another
machine. For instance, for a standard button control, what if I invoke:

Type.GetType("System.Windows.Forms.Button, System.Windows.Forms,
Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")

on machine B where the name originated from machine A. Will this always work
so long as .NET 2.0 is the minimum required version on machine B (as seen
above)? I'm not sure if the PublicKeyToken seen above factors in at all
(will it always be the same regardless of the version of .NET?). Thanks for
your help.
 
Hi,

IMO it should work.

Why you need to especify the PublicKeyToken anyway?
 
IMO it should work.
Why you need to especify the PublicKeyToken anyway?

Thanks for the feedback. I'm reading it from a native .NET resource file
where it applies the fully-qualified type name. Anyway, thanks again.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top