2

In an MVC3 (razor) web app, I want to use the expression syntax for begin form, ex. @Html.BeginForm(c => c.ActionName(null)). However, I don't see an overload that takes an expression and the page throws an error when I try it.

Am I forgetting a step? Do I need to include an additional namespace, or some 3rd party resource? I'm using MvcContrib.FluentHtml, but I don't see it in there either.

tereško
  • 58,060
  • 25
  • 98
  • 150
Joe
  • 63
  • 5

1 Answers1

2

The lambda overload of BeginForm is part of ASP.NET MVC Futures, which for MVC 3 can be downloaded here: http://aspnet.codeplex.com/releases/view/58781

Curtis Buys
  • 2,341
  • 1
  • 17
  • 13
  • Worked perfectly, thanks! On a side note I couldn't use @Html.BeginForm<>(), I had to use @using(Html.BeginForm<>()) {. – Joe Apr 08 '12 at 12:23