Reputation: 1615
I have a drop down list on my aspx form and what I want is to refresh the site after I select an item from the list. This is my drop down list:
<%: Html.DropDownListFor(x => x.CompanyUserFilterId, new SelectList(Model.CompanyUsers, "Id", "FirstName", Model.CompanyUserFilterId))%>
I use it to filter the data shown on the form depending on the selected item on the drop down list. Please help :)
Upvotes: 0
Views: 2069
Reputation: 2293
The simplest method is probably to trigger an html/javascript onchange-event, and handle that to update your page (or post the form with the selected Id).
Take a look at this: http://blog.wekeroad.com/2008/10/21/asp-net-mvc-dropdownlist-and-html-attributes
Upvotes: 1