0
我正在開發一個MVC3 web應用程序。我想要一個顯示在視圖中的旋轉列表。但是構建過程中出現了錯誤:MVC3 Razor SelectList.MakeSelection問題
Error 2971 'System.Web.Mvc.SelectList' does not contain a definition for 'MakeSelection' and no extension method 'MakeSelection' accepting a first argument of type 'System.Web.Mvc.SelectList' could be found (are you missing a using directive or an assembly reference?).
我的代碼鑑於:
<div class="editor-field">
@Html.DropDownListFor(model => model.JobFiles[i].JobPages[j].UserRotation, (ViewData["rotation"] as SelectList).MakeSelection(Model.JobFiles[i].JobPages[j].UserRotation))
</div>
請幫助。 Thx提前。