This repository was archived by the owner on Mar 2, 2023. It is now read-only.
This repository was archived by the owner on Mar 2, 2023. It is now read-only.
Web API Dependency Injection with Unity error - No public constructor is available for type System.Web.Http.Dispatcher.IHttpControllerActivator #17
Open
Description
I am trying to implement the dependency injection in ASP.Net web API with unity container and have implemented the exactly with below 2 articles:
- https://stackoverflow.com/a/38770689/3698716
- https://docs.microsoft.com/en-us/aspnet/web-api/overview/advanced/dependency-injection
Both are related to each other with some minor change but implementation for both are the same.
After implementing I am getting an error in the method GetService in UnityResolver.cs class:
"Resolution failed with error: No public constructor is available for type System.Web.Http.Dispatcher.IHttpControllerActivator."
Metadata
Metadata
Assignees
Labels
No labels