title: Razor is capitalizing "True" when setting a range for validation in my model. Html boxes use lowercase "true". How can I get around that?
body: <p>I'm trying to do input validation for an @html checkbox, but given that Razor uses ToString for bools and the like, everything comes out as capitalized. This means that my input validation range and html</p>
  <p><code>[Range(typeof(bool), &quot;true&quot;, &quot;true&quot;, ErrorMessage = &quot;Residency is required&quot;)]</code></p>
  <p><code>@Html.CheckBoxFor(m =&gt; m.IsResident, new { @id = &quot;residentChk&quot; })</code></p>
  <p>Ends up displaying in the source as</p>
  <p><code>&lt;input data-val=&quot;true&quot; data-val-range=&quot;Residency is required&quot; data-val-range-max=&quot;True&quot; data-val-range-min=&quot;True&quot; data-val-required=&quot;The IsResident field is required.&quot; id=&quot;residentChk&quot; name=&quot;IsResident&quot; type=&quot;checkbox&quot; value=&quot;true&quot; /&gt;&lt;input name=&quot;IsResident&quot; type=&quot;hidden&quot; value=&quot;false&quot; /&gt;</code></p>
  <p>With the main culprits of the issue being</p>
  <p><code>data-val-range-min=&quot;True&quot; data-val-range-min=&quot;True&quot;</code></p>
  <p>Is there anyway to get razor to put these value in as lower case values, or to somehow modify the checkbox to return an upper case value? Im trying to keep parity with the other parts of the code, so I dont want an edge case that handles this with one off js functions if at all possible.</p>