title: Error :the namespace '<global namespace>' already contains a definition for 'AboutDialog1'
body: <p>I am a newbie to WPF. 
  I am practising the sample code in WPF unleashed .
  When I was trying to implement the Attached events , I modified the class name an Xaml file to a different class name , that is as same as my namespace of  the new page and I am debugger 
  complains with this error:</p>
  
  <blockquote>
    <p>Error 1   The namespace '' already contains a definition for 'AboutDialog1'</p>
  </blockquote>
  
  <p>Can anybody please let me know why am I getting such errors?</p>
  
  <p>my code :</p>
  
  <pre><code>&lt;Page 
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        x:Class="AboutDialog1" ListBox.SelectionChanged ="ListBox_selectionchanged"
  
      Title="attachedevents"&gt;
      &lt;StackPanel&gt;
          &lt;Label FontWeight="Bold" FontSize="20" Foreground="White"&gt;wp4 unleashed &lt;/Label&gt;
          &lt;ListBox&gt; 
              &lt;ListBoxItem&gt;chapter 1&lt;/ListBoxItem&gt;
              &lt;ListBoxItem&gt;chapter 2&lt;/ListBoxItem&gt;
          &lt;/ListBox&gt;
      &lt;/StackPanel&gt;
  </code></pre>
  
  <h2>    </h2>
  
  <pre><code>namespace AboutDialog1
  {
      public partial class AboutDialog: Page
      {
          public AboutDialog()
          {
  
          }
          void ListBox_selectionchanged(object sender, SelectionChangedEventArgs e)
          {
              if (e.AddedItems.Count &gt; 0)
                  MessageBox.Show("you have selected " + e.AddedItems[0]);
  
          }
  
      }   
  </code></pre>