I’ve got a pretty noob question for ya. I keep seeing this syntax:
<%= Html.LabelFor(model => model.Email) %>
…and I have no idea what the => means. I thought it was syntax for linq2sql or ado.net entity framework but I’m just using straight ado.net. I don’t understand why the VWD used that syntax when generating the Create form.
What does => mean?
it is a lambda expression it means “goes to”
this is a pretty good link for explaining here
the left side is the input the right side the expression or statement block, here you are calling the LabelFor method inputing model and using the Email field on the model passed in.