I have a problem when I want to bind a value from my model to a textbox, here is my MVC view code:
@Html.TextBox("SellerBroker", model => model.OutOfMarket.BuyerBroker.Name , new { @class = "control-label" })
I want my textbox to have a name or 'SellerBroker' and it's value to come from my model property model => model.OutOfMarket.BuyerBroker.Name
and with HTML attributes of class = "control-label"
. However, I am receiving the following error:
Cannot convert lambda expression to type 'object' because it is not a delegate type