string keyword=this.txt_keyword.Text;
string tempstr=this.txt_tempstr.Text;
var q=from n in NS       //这个只是 个测试写法,因为时间紧就没完整的贴出来,后面的字段值在集合里面并不一定存在
where (!string.IsNullOrEmpty(keyword) ? (news.Field<string>("Title") != null&&news.Field<double>("Title") == keyword) : true)
&& (!string.IsNullOrEmpty(tempstr) ? news.Field<string>("cccField") == tempstr : true) 
 
条件多的话,同理按上面方式添加&&

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-10-31
  • 2021-09-25
  • 2021-06-04
  • 2022-12-23
  • 2021-06-03
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-09-02
  • 2022-12-23
  • 2022-12-23
  • 2021-08-26
  • 2021-06-25
相关资源
相似解决方案