How to filter two DataTables in C#? -
how filter 2 tables in c#? table 1 contains full data , table 2 contains content of table one?
what want (it's not clear question)? take table1, filter , pass result table2? then:
dataview dv = table1.asdataview(); dv.rowfilter = fexpression; // example "myid = 3" datatable table2 = dv.totable(); // if want typed datatable, can (although there other ways): mytypeddatatable table2 = new mytypeddatatable(); datatable temptable = dv.totable(); table2.merge(temptable);
Comments
Post a Comment