title: Register custom controller in runtime
body: <p>I've some api controller that i want to register at runtime in my mvc application.
  The controller itself resides into Class Library project and looks like:</p>
  
  <pre><code>public class CustomController : ApiController
  {
      public string Get()
      {
          return "Hello";
      }       
  }
  </code></pre>
  
  <p>I've compile that library (gave it a name <code>Injection.dll</code>), and in my mvc app try to register those controller via Unity.Mvc library container</p>
  
  <pre><code>public static class UnityConfig
  {
      public static void RegisterComponents()
      {
          var container = new UnityContainer();
  
          // register all your components with the container here
          // it is NOT necessary to register your controllers
  
          // e.g. container.RegisterType&lt;ITestService, TestService&gt;();
  
          Assembly customLogicAssembly = Assembly.LoadFrom(HttpContext.Current.Server.MapPath("~/bin/" + "Injection.dll"));
          Type existingType = customLogicAssembly.GetTypes().First();
          container.RegisterType(existingType);
  
          DependencyResolver.SetResolver(new UnityDependencyResolver(container));
      }
  }
  </code></pre>
  
  <p>So it seems that registration works fine and i have no errors while debuggig it, but 
  i don't have expected result, when i navigate to api/Custom/Get  i have an <strong><code>The resource cannot be found.</code></strong> error in browser.
  Pls help what i miss here.</p>