【发布时间】:2012-10-16 16:27:24
【问题描述】:
我面临以下问题。我想要一个旁边有一个 DropDowList 的搜索字段,用户可以在其中选择他想要搜索的项目。我必须使用这个 LINQ 代码,而不仅仅是 SQL 查询。
这是我的代码:
var Metadata = from m in db.Metadatas
join mm in db.Multimedias
on m.multimediaID equals mm.multimediaID
where (m. { Here would i have the selected value from the dropdownlist. } .ToString().Contains(textboxvalue) ||
mm. { Here would i have the selected value from the dropdownlist. } .ToString().Contains(textboxvalue))
&& mm.filetype.ToString().Contains(radiobuttonvalue)
我想在区域中添加类似:“Dropdownlist.selectedvalue”的内容{ 这里我会从下拉列表中选择值。 }
希望你们能理解我的想法和问题。
【问题讨论】:
-
你的问题是什么?你从来不说。
-
我想让我的“dropdownlist.selectedvalue”在我说的区域:{ 这里我会从下拉列表中选择值。 }