WebAPI + EPi + .NET 4.5 not working

Marija Jemuovic
Member since: 2010

Hi, everyone,

I've followed the example here:



However, I've stumbled upon the first step: registering a route. This is the error I get on:

 System.Net.Http.HttpMessageHandler' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Net.Http, Version=, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a


                       name: "ActionApi",
                       routeTemplate: "api/{controller}/{action}/{id}",
                       defaults: new { id = RouteParameter.Optional }


Anyone had the same problem? And a solution?



#73113 Jul 05, 2013 17:14
  • Jeroen Stemerdink
    Member since: 2009

    The problem might be that System.Net.Http is already included in 4.5. The reference in your project probably points to the one in the webapi package, which is needed for 4.0? If so, just remove that reference and add one to the one included in the framework. Hopefully that will solve your problem.

    #73122 Jul 07, 2013 9:27

    Version is also an old version, afaik you should use version


    #73124 Jul 08, 2013 8:43