我想从列表中生成一个DataTables。Howto someFunction(List <acceptDifferentTypesHere> list){/ * reflection stuff * /}
so f.e.我有两个列表
List<typeA> listA = new List<typeA>();
List<typeB> listB = new List<typeB>();
我怎样才能得到一个函数接受两个(或超过这些)列表与不同的元素类型?
private void someFunction(List<acceptDifferentTypesHere> list)
{
/*elementwise reflection stuff*/
}
任何帮助将是不错,
哈利
你知道在编译时的typeA或TYPEB? – 2012-01-18 15:16:03
是的,我知道他们两人。 – Harry 2012-01-18 15:22:00
所以msarchet你答案! – 2012-01-18 15:34:42