dropdownfor

Convert my List<Roomtype> to SelectList for ASP. NET MVC DropDownFor<>, and get the correct values per option item

I have my class RoomType: Int32 Id String Name String ColorCode My viewmodel gets a List<Roomtype> RoomTypes which should be displayed in a dropdown. Each dropdown option item should have: 1) as title the Name, 2) as value the Id, and 3) the style background-color #ColorCode. My problems are how to convert this list correctly into ...