title: DataTemplate button command from binding
body: <p>I'm using Wpf and I'm passing a <code>List&lt;Value&gt;</code> to a <code>&lt;ItemsControl&gt;</code> in the xaml. I would like to bind the <code>string</code> in the <code>Value</code> Object to the Command of a Button. This xaml part looks like this:</p>
  
  <pre><code>    &lt;Grid Margin="0,0,2,0"&gt;
      &lt;Grid Margin="10"&gt;
          &lt;ItemsControl Name="details"&gt;
              &lt;ItemsControl.ItemTemplate&gt;
                  &lt;DataTemplate&gt;
                      &lt;Grid Margin="0,0,0,5"&gt;
                          &lt;Grid.ColumnDefinitions&gt;
                              ....
                          &lt;/Grid.ColumnDefinitions&gt;
                          ...
                          &lt;Button Grid.Column="2"
                                  Content="{Binding ButtonContent}"
                                  Visibility="{Binding ButtonVisibility}"
                                  Command="{Binding ButtonClickMethod}" /&gt;
          ...
  </code></pre>
  
  <p>My <code>Value</code> Class looks like this:</p>
  
  <pre><code>public class Value
  {        
      ...
      public string ButtonClickMethod { get; set; }
  
  }
  </code></pre>
  
  <p>I'm setting the string link this:</p>
  
  <pre><code>v.ButtonClickMethod = "RelatedActivityId_OnClick";
  </code></pre>
  
  <p>And the Method is in the same class and looks like this:</p>
  
  <pre><code>private void RelatedActivityId_OnClick(object sender, RoutedEventArgs e)
      {
          MessageBox.Show("RelatedActivityId_OnClick");
      }
  </code></pre>
  
  <p>Everything besides this is working properly and unses the same Object for the binding.
  What am I doing wrong?</p>