title: WPF button in ListView can not see command in ViewModel
body: <pre><code>&lt;StackPanel&gt;
          &lt;!--&lt;Button Command="{Binding GetOddsCommand}" CommandParameter="{Binding}" /&gt;--&gt;
  
      &lt;ListView 
          ItemsSource="{Binding Links}"
          &gt;
          &lt;ListView.ItemTemplate&gt;
              &lt;DataTemplate&gt;
                  &lt;Border&gt;
                      &lt;Button Command="{Binding GetOddsCommand}" CommandParameter="{Binding}"&gt;
                          &lt;TextBlock &gt;
                          &lt;Hyperlink NavigateUri="http://www.onet.pl" &gt;
                              &lt;TextBlock Text="{Binding}" /&gt;
                          &lt;/Hyperlink&gt;
                      &lt;/TextBlock&gt;
                      &lt;/Button&gt;
                  &lt;/Border&gt;
              &lt;/DataTemplate&gt;
          &lt;/ListView.ItemTemplate&gt;
  </code></pre>
  
  <p>I have MVVM application. In viewmodel I have GetOddsCommand:</p>
  
  <pre><code>public ICommand GetOddsCommand
  {
      get
      {
          if (_getOddsCommand == null)
              _getOddsCommand = new RelayCommand(param =&gt; GetOdds());
          return _getOddsCommand;
      }
  }
  
  private void GetOdds()
  {
  
  }
  </code></pre>
  
  <p>When I uncomment first button placed in StackPanel command works good. Debugger step into get and then when I click command Debugger step into GetOdds method. But it doesn't work in second button which is in the ListView. Looks like second button cannot see GetOddsCommand, but I don't understand why</p>
  
  <p>Thanks</p>