MVC-3 and Html.Serialize (ASP.NET 4, MVC3)

Currently working on a project in MVC-3. Trying to put the following code in my opinion, but Visual Studio tells me that it cannot find the Serialize method.

@Html.Serialize("User",Model) 

(ex)

 @using (Html.BeginForm()) { @Html.Serialize("User",Model) <fieldset> ... </fieldset> } 

Is this feature missing in MVC-3? I see examples of people using it in MVC-2. Perhaps there is a new way to solve this problem?

+7
source share
4 answers

Html.Serialize is in the Futures assembly.

+6
source

Install the Nuget package: Install-Package Mvc3Futures .

In your view, add a link to the Microsoft.Web.Mvc namespace, then you can use Html.Serialize .

+6
source

Serialize() not listed here .

It is not part of Sys.Web.Mvc , but is currently part of Microsoft.Web.Mvc :

+2
source

I downloaded the futures, deleted the link to my local System.Web.Mvc (v3) and added the release version from the GAC and included the new futures DLL in the project.

0
source

All Articles