标签:
public List<string[]> SetList(DataTable dt)
{
List<string[]> list = new List<string[]>();
foreach (DataRow r in dt.Rows)
{
int colCount = r.ItemArray.Count();
string[] items = new string[colCount];
for (int i = 0; i < colCount; i++)
{
items[i] = Convert.ToString(r.ItemArray[i]);
}
list.Add(items);
}
return list;
}
标签:
原文地址:http://www.cnblogs.com/-lxl/p/5856498.html