string tempSFZH = "";
foreach (DataRow rs in ds.Tables[0].Rows)
{
tempSFZH = rs[ht["身份证号码"].ToString()].ToString();
foreach (DataRow rs1 in ds_stuAll.Tables[0].Rows)
{
foreach (DataColumn dc in ds_stuAll.Tables[0].Columns)
{
if (dc.ColumnName == "sfzh" && rs1[dc].ToString() == tempSFZH)
{
rs1["xjh"] = "";
rs1["user_xh"] = "";
}
}
}
}
转载于:https://www.cnblogs.com/miraclesakura/p/3737328.html