@Html.TextBoxFor(m => m.YourProperty, new { @class = "MyClass", @Value = string.Format("{0:C}",Model.YourProperty) })
You can do this using EditorFor and the DisplayFormat annotation. However, you loose the ability to add class to your textbox.
Save my sunday afternoon. Tks!
ReplyDelete