I am using the BreezeApi NuGet package in my project. It is in Visual Studio 2013.
I get this error.
Error 41 Assembly 'Breeze.WebApi2, Version=1.4.0.0, Culture=neutral, PublicKeyToken=f6085f1a45e2ac59' uses 'System.Web.Http, Version=5.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' which has a higher version than referenced assembly 'System.Web.Http, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35'
I don't know why my project keeps referencing the 4.0 version. Things I tried:
I removed the reference of system.web.http 4.0 from my project and browsed to the 5.0 DLL file location. As soon as I add it and come back to Solution Explorer, right click on the system.web.http dll, it is showing 4.0.0.0.
I added assembly binding in web.config like below
<dependentAssembly> <assemblyIdentity name="System.Web.Http" publicKeyToken="31bf3856ad364e35" culture="neutral" /> <bindingRedirect oldVersion="0.0.0.0-5.1.0.0" newVersion="5.1.0.0" /> </dependentAssembly>
How do I resolve this?