1.定义表结构

DataTable DT = new DataTable();


DT.Columns.AddRange(new[]
{
new DataColumn("YDNo",typeof(string)),
new DataColumn("Company",typeof(string)),
new DataColumn("ManageNo",typeof(string)),
new DataColumn("ShareFee",typeof(decimal))
});

DT.Rows.Add("98001", "福永分公司", "IC-001", 0);
DT.Rows.Add("98002", "南山分公司", "IC-002", 0);
DT.Rows.Add("98003", "福田分公司", "IC-002", 0);
DT.Rows.Add("98004", "福永分公司", "IC-001", 0);
DT.Rows.Add("98005", "福永分公司", "IC-003", 0);
View Code

相关文章: