c# - Howto someFunction(List list) { /*reflection stuff*/ } -



c# - Howto someFunction(List<acceptDifferentTypesHere> list) { /*reflection stuff*/ } -

i want generate datatables out of lists.

so f.e. got 2 lists

list<typea> lista = new list<typea>(); list<typeb> listb = new list<typeb>();

how can function accepting both (or more theese) lists different element type?

private void somefunction(list<acceptdifferenttypeshere> list) { /*elementwise reflection stuff*/ }

any help nice,

harry

private void somefunction<t>(list<t> list) { /*elementwise reflection stuff*/ }

used follows

somefunction<typea>(lista); somefunction<typeb>(listb);

c# asp.net function collections

Comments

Popular posts from this blog

How do I check if an insert was successful with MySQLdb in Python? -

delphi - blogger via idHTTP : error 400 bad request -

postgresql - ERROR: operator is not unique: unknown + unknown -