Here is the sample code I figure out, using System; namespace X var GenericType = Type.GetType("X." + byString); var genericMethod = typeof(Program).GetMethod("GetList") var output = genericMethod.Invoke(null, new object[] { GenericIns }); public static T GetList<T>(T input) where T : new() class Today class Tomorrow |
Pages
▼
No comments:
Post a Comment