Monday, June 20, 2011

How to Load Assambly in Memory using Reflection

using System;

using System.Collections.Generic;
using System.Text;
using System.Reflection;

namespace Assamblly
{
    class Program
{

static void Main(string[] args)

{

Assembly objAssembly = Assembly.LoadFrom(@"C:\Windows\Microsoft.NET\Framework\v2.0.50727\mscorlib.dll");



foreach (Type objType in objAssembly.GetTypes())

{

Console.WriteLine(objType.ToString());

}

}

}

}



0 comments:

Post a Comment