I\'m using Web.api and Unity and I am getting the following error when trying to open the default \"help\" area:
[InvalidOperationException: The type String cann
Registering the HttpConfiguration object as an instance in UnityContainer will also help resolve the issue.
Just need to add to add the below line while registering in UnityContainer.
public static void RegisterTypes(IUnityContainer container) {
container.RegisterInstance(GlobalConfiguration.Configuration);
}
This will help Unity resolve the config parameter, when it invokes the constructor with the parameter.
public HelpController(HttpConfiguration config) {
Configuration = config;
}