title: WPF Prism Module error resolving IUnityContainer
body: <p>I have a very basic prism application which I am trying to use as a start to a larger project. I have a shell with a single region defined called "MainContent". There are 3 modules in the project. A MainMenuModule, a MovieModule, and a TVModule. The Movie and TV modules are dependent on the MainMenuModule. Modules are loaded using a DirectoryModuleCatalog. The issue occurs when the TVModule is included, more specifically an exception is thrown when the contructor for TVModule is called. The constructor below will throw an error:</p>
  
  <pre><code>public TVModule(IUnityContainer container, IRegionManager manager)
  {
      _container = container;
      _manager = manager;
  }
  </code></pre>
  
  <p>If I change the constructor to the following I get no exception and the TVModule loads as expected.</p>
  
  <pre><code>public TVModule(IRegionManager manager)
  {
      _manager = manager;
  }
  </code></pre>
  
  <p>The exception I get is thrown when Unity tries to resolve IUnityContainer. What is really baffling me is the fact that MovieModule's contructor is exactly the same as TVModule's and yet works without issue. Exception detail.</p>
  
  <blockquote>
    <p>{"Resolution of the dependency failed, type = \"TVModule.TVModule\", name = \"(none)\".
    Exception occurred while: while resolving.
        Exception is: InvalidOperationException - The current type, Microsoft.Practices.Unity.IUnityContainer, is an interface and cannot be constructed. Are you missing a type mapping?
        At the time of the exception, the container was:</p>
    
    <p>Resolving TVModule.TVModule,(none)
        Resolving parameter \"container\" of constructor TVModule.TVModule(Microsoft.Practices.Unity.IUnityContainer container, Microsoft.Practices.Prism.Regions.IRegionManager manager)
        Resolving Microsoft.Practices.Unity.IUnityContainer,(none)
        "}</p>
    
    <p>{"The current type, Microsoft.Practices.Unity.IUnityContainer, is an interface and cannot be constructed. Are you missing a type mapping?"}</p>
  </blockquote>
  
  <p>EDIT: I have uploaded a copy of my source to dropbox <a href="http://dl.dropbox.com/u/56578152/Media.zip" rel="nofollow">here</a></p>