Can I set text box to readonly when using Html.TextBoxFor?
<%= Html.TextBoxFor(m => Model.Events.Subscribed[i].Action, new { @readonly = true })%>
Use the following:
@Html.TextBoxFor(m => m.Whatever, new {@readonly = "readonly"})
If you want to assign a class to it you could do it the same way , by adding the @class = "" property. Hope this helps :)