1 if (ds.Tables[0].Rows.Count == 0)
2             {
3                 AddDummyData(ds);
4             }
 1  private void AddDummyData(DataSet ds)
 2     {
 3 
 4         // Add a dummy row
 5 
 6         DataTable dt = ds.Tables[0];
 7 
 8         DataRow newRow = dt.NewRow();
 9 
10         dt.Rows.Add(newRow);
11 
12     }

相关文章:

  • 2021-06-23
  • 2021-11-20
  • 2021-12-07
  • 2022-02-25
  • 2021-08-18
  • 2022-01-03
  • 2021-12-16
  • 2021-07-11
猜你喜欢
  • 2022-12-23
  • 2021-12-20
  • 2021-10-26
  • 2021-08-12
  • 2022-12-23
  • 2021-10-22
  • 2022-12-23
相关资源
相似解决方案