Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想比较表列字段的搜索值,如果我只比较包含属性的字符串值,则没有错误,但如果同时比较数字和字符串值,则显示
不接受 1 个参数
如附图所示
您正在使用单一=的赋值运算符。对于比较使用==运算符:
=
==
Where(p => p.VenerName.Contains(searchText) || p.PrimaryContact == id)