DataRow row; if (row.Table.Columns.Contains("id"))//判断row 是否存在指定列 { //如果存在 string a=row["id"].ToString(); }