C#可以实现动态的实例化,但不可以实现动态的类继承。
C#中同样可以使用反射实现实例化。在System.Reflect下。动态实例化使用System.Activator.CreateInstance(Type);

解决方案 »

  1.   

    to colinfly(Colin) 
        能给点具体的例子嘛?我对这个还不是太了解。谢谢
      

  2.   

    http://expert.csdn.net/Expert/topic/2214/2214138.xml?temp=.9719202
      

  3.   

    给你个实例http://www.luocong.com/bbs/dispbbs.asp?boardID=2&ID=2958
      

  4.   

    acewang(**^o^**) ( ) 信誉:100 给出的例子非常好,可以说该说的都说了System.Windows.Forms.Form f= (System.Windows.Forms.Form)  System.Activator.CreateInstance(System.Reflection.Assembly.GetExecutingAssembly().GetType("TreeViewNode.Form1"));
    f.Show();
    System.Windows.Forms.Form f= (System.Windows.Forms.Form)  System.Activator.CreateInstance(this.GetType());
    f.Show();
    这里是简单的例子。