For some reason an HTML helper is outputting this HTML which doesn’t validate.
The validator tells me:
There is no attribute "Length"
<%= Html.CheckBox("Medicamentos", Model.Medicamentos) %>
is outputting
<input type="checkbox" value="true" name="Medicamentos" id="Medicamentos" checked="checked" length="4">
I assume that it’s matching the signature that takes a string and an object since I don’t know what
Model.Medicamentosis. In that case it takes the properties of the object and turns them into attributes on the element. I suspect that you simply want to use theCheckedattribute on the Model property specified as the default value of the checkbox, i.e.,In, which case, assuming that
Checkedis boolean it will match the correct method signature on the helper extension.