方法1~ !string.IsNullOrEmpty()

1 if (!string.IsNullOrEmpty(System.Web.HttpContext.Current.Request.QueryString["id"]))
2 {
3     Convert.ToInt32(Request.QueryString["id"]);
4 } 

方法2~ try{} catch{}

1 try
2 {
3     model_weekplandetails.constructiion_complete_time = DateTime.Parse(ds.Tables[0].Rows[i]["constructiion_complete_time"].ToString());
4 }
5 catch { }

未完待续,欢迎补充~

 

相关文章:

  • 2022-12-23
  • 2021-09-24
  • 2021-11-27
  • 2021-06-14
  • 2021-11-28
  • 2021-12-04
猜你喜欢
  • 2022-02-24
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-01-11
  • 2021-09-18
相关资源
相似解决方案