Can anyone please tell me how to write Controller for C# (public ActionResult DropList()
) for Drop Down List generate Linq I want convert this SELECT DISTINCT CouName FROM Locations;
to Linq for my drop down list dynamically generate.
Chtml page how do I write in @Html.DropDownListFor("")
Models.Location
Assuming you model is named
MyModel
Controller
View