标签:ar sp 数据 ad bs new table nbsp view
DataTable dt = new DataTable();
dt.Columns.Add("id");
dt.Columns.Add("value");
DataRow dr = dt.NewRow();
dr["id"] = "1";
dr["value"] = "1";
dt.Rows.Add(dr);
dr = dt.NewRow();
dr["id"] = "1";
dr["value"] = "2";
dt.Rows.Add(dr);
dr = dt.NewRow();
dr["id"] = "2";
dr["value"] = "22";
dt.Rows.Add(dr);
//将dt中的重复数据过滤掉
DataView myDataView = new DataView(dt);
//此处可加任意数据项组合
string[] strComuns = { "id"};
dt = myDataView.ToTable(true, strComuns);
标签:ar sp 数据 ad bs new table nbsp view
原文地址:http://www.cnblogs.com/lsyyx/p/4047351.html