Error binding to target method
问题 I am trying to call a static method from a helper class, of which the type is not known until runtime. I thought I had solved the problem however I am getting the following error - "Error binding to target method." Can anyone see what is wrong with this code? Any help would be appreciated.. Delegate del = Delegate.CreateDelegate(typeof(Func<string>), typeof(RepositoryStringExtensions).GetMethod("GetTableName", BindingFlags.Static | BindingFlags.Public) .MakeGenericMethod(new Type[] {