I’ve just installed Visual Studio 2012 and started checking out MVC 4 and Web Api.
I’ve created a new MVC 4 app with Web API. Based on some examples and tutorials I started configuring my routes with:
routes.MapHttpRoute(
name: "Controller only",
routeTemplate: "api/{controller}"
);
However, that results in an error that RouteCollection doesn’t contain a definition for MapHttpRoute. Am I missing some DLLs installed?
As far as I could see I have all the right DLLs and version installed.
I have solved it by adding a reference to
System.Web.Httpin RouteConfig.cs