This question is locked. New answers and comments are not allowed.
I have the following view where the MarketId is a Guid. When I look at the source of the html the dropdown is rendered correctly but when I hit submit the marketid is not being passed. I also have a textbox on the page and that passes back the data just fine.
Any suggestions?
Here is my ViewData where Zone is actually getting passed back to my Service and the rest of the objects are just to fill the Comboboxes.
ViewData
View
Any suggestions?
Here is my ViewData where Zone is actually getting passed back to my Service and the rest of the objects are just to fill the Comboboxes.
ViewData
public class ZonesViewData : BaseViewData { public List<Market> Markets { get; set; } public List<Zone> PossibleParentZones { get; set; } public List<Zone> Zones { get; set; } public Zone Zone { get; set; } }View
<% Html.EnableClientValidation(); %> <% using (Html.BeginForm()) {%> <%: Html.ValidationSummary(true) %> <div class="editor-label"> <%: Html.LabelFor(model => model.Zone.MarketId) %> </div> <div class="editor-field"> <%: Html.Telerik().ComboBoxFor(model => model.Zone.MarketId) .Name("cmbMarketId") .BindTo(new SelectList(Model.Markets, "MarketId", "Name")) .HtmlAttributes(new { style = string.Format("width:200px") }) %><p><input type="submit" value="Create" /></p> <% } %>