Wednesday, 2 November 2016

Fix - MVC Error: 'object' does not contain a definition for ''

Watch this example on YouTube

To fix it replace
   @Html.TextBoxFor(model => model.CustomerID, new  object { @class = "WidthLong" })
With
   @Html.TextBoxFor(model => model.CustomerID, new  { @class = "WidthLong" })

No comments:

Post a Comment