title: Catel MVVM Structure
body: <p>I have a simple WPF Application and I used Catel (3.5) framework for using MVVM.
  The Default structure for Catel in visual studio is:</p>
  
  <pre><code>Solution:
    Project:
      FolderView
      FolderViewModel
      FolderModel
  </code></pre>
  
  <p>I want to change the structure to </p>
  
  <pre><code>Solution:
    ProjectView
    ProjectViewModel
    ProjectModel
  </code></pre>
  
  <p>in this way I completely separate M-VM-V and I add reference.</p>
  
  <p>I Understand that Catel scans the project automatically to find the Viewmodels if the naming convention are respected.</p>
  
  <p>I can not make this work on the second structure, any advice will be pretreated.</p>
  
  <p><strong>EDIT</strong> 1:
  I have added the following code in App.xaml.cs</p>
  
  <pre><code>var viewModelLocator = ServiceLocator.Default.ResolveType&lt;IViewModelLocator&gt;();
  viewModelLocator.NamingConventions.Add("CatelV2ViewModel.ViewModels.[VW]ViewModel");
  </code></pre>
  
  <p>This does not work for me, and I have No Idea why. Im sure that My assembly name is correct AND I end my class name with <em>ViewModel</em>.</p>
  
  <p><strong>EDIT</strong> 2:
  The application Works if I add the following code:</p>
  
  <pre><code>viewModelLocator.Register(typeof(MainWindow), typeof(MainWindowViewModel));
  </code></pre>
  
  <p>But I still want to know why it dosent work when I add a NamingConvention.</p>