判断DataTale中判断某个字段中是否包含空值

 DataRow[] dataRows = dt.Select("isnull("+ columnName  +", '') = ''");
    if (dataRows.Length > 0)
     {
           MessageBox.show("[" + columnName  + "]列包含空值数据");
            return ;
      }

  

猜你喜欢

转载自www.cnblogs.com/xiaoheihei/p/11388368.html
今日推荐