Search This Blog

Tuesday, January 10, 2012

C# Using reflection to create an instance of a specific type; convert string to a specific type;

The idea behind the post is to convert a string such as: “System.Int32” to an instance of a specific type.
To create an instance of a compiled custom class in the assembly:


To create an instance of a built-in type e.g. “System.Int32” :

1 comment:

  1. Hi, Great.. Tutorial is just awesome..It is really helpful for a newbie like me.. I am a regular follower of your blog. Really very informative post you shared here. Kindly keep blogging. If anyone wants to become a .Net developer learn from .Net Training in Chennai. or learn thru ASP.NET Essential Training Online


If you like this post, please leave a comment :)