请问如何在Razor视图引擎中设置断点测试Lambda表达式?
比如,我有以下代码:
@(Html.DropDownList("Condition4",
new SelectList(Model
.Conditions
.Where(c =>
c.TxCondition.TxConditionTypeId == Model.ConditionTypes.Single
ct => ct.TxConditionType.ConditionTypeCode == "Region")
.TxConditionType
.TxConditionTypeId),
"TxCondition.TxConditionId",
"ConditionTitle",
Model.SearchCondition.Condition4),
"All"))
在断点处,我尝试使用“快速监视窗口”测试以下代码,但出现了错误“表达式不能包含lambda表达式”
请问如何在MVC Razor视图中测试lambda表达式?
非常感谢您的时间和帮助。
Model.Conditions.Where(c => c.TxCondition.TxConditionTypeId == 1)