title: How to enable/disable Html helper on MVC view
body: <p>I'm starting to play around with MVC. I did the NerdDinner walkthrough and now I'm creating a simple project that displays the products in the Northwinds database. I have a details view, a create view, and an edit view. I figured out how to display a checkbox for the boolean property, "Discontinued", but I want the control to be disabled on the details view (since the edit view is used for editing). This is what I have:</p>
  
  <pre><code>&lt;div class="display-label"&gt;Discontinued: &lt;%: Html.CheckBoxFor(Function(model) model.Discontinued)%&gt;&lt;/div&gt;
  </code></pre>
  
  <p>I'm not sure how to get to or set the enabled property of the checkbox. (I suppose I could do it using javascript, but I'm thinking there is a better way). Thanks for the help.</p>