@Html.ActionLink and @Html.DisplayFor at the same time (not right, but it describes what I want to do)

前端 未结 3 1830
遇见更好的自我
遇见更好的自我 2021-02-12 09:38

I have the following table located in a view within a controller named Student (/Student/Details/1):

    @foreach (var item in Model.Enrollments)
    {
        &         


        
3条回答
  •  别那么骄傲
    2021-02-12 10:40

    You forgot an ) after Html.DisplayFor(modelItem => item.Course.Title.

    Maybe try adding a .ToString() to it might help.

提交回复
热议问题