I have installed Microsoft.AspNet.WebApi.Cors
package using Install-Package Microsoft.AspNet.WebApi.Cors
in my WebApi project(.net framework 4.5.2)
make sure your packages are up to date. if you update and you still have the same error - uninstall your packages one by one until you get your system.web.http disappear from the references - then add the references again this should fix your build error
You need to install following nuget package for this.
Install-Package Microsoft.AspNet.WebApi.Cors.ko -Version 5.0.0
This will work.
I had same issue, but doing this "Update-Package –reinstall Microsoft.AspNet.Cors" fixed my problem