title: Access current ItemsControl index via binding
body: <p>I have the following piece of code </p>
  
  <pre><code> &lt;ItemsControl x:Name="ItemsControl" ItemsSource="{Binding Offers}"&gt;
                  &lt;ItemsControl.ItemsPanel&gt;
                      &lt;ItemsPanelTemplate&gt;
                          &lt;StackPanel Orientation="Vertical"&gt;&lt;/StackPanel&gt;
                      &lt;/ItemsPanelTemplate&gt;
                  &lt;/ItemsControl.ItemsPanel&gt;
                  &lt;ItemsControl.ItemTemplate&gt;
                      &lt;DataTemplate&gt;
                          &lt;wpf:Card Padding="32" Margin="5" d:DataContext="{d:DesignData }"&gt;
                              &lt;StackPanel Margin="0,0,0,-30" Height="107"&gt;
                                  &lt;TextBlock
                                      Style="{DynamicResource MaterialDesignTitleTextBlock}"&gt;
                                      &lt;Run Text="Offer " /&gt;
  
                                  &lt;/TextBlock&gt;
                                  &lt;TextBlock Text="{Binding CarDescription}" /&gt;
                                  &lt;Separator Height="1" Visibility="Hidden" /&gt;
                              &lt;Button Content="Select" 
                                          Width="72" 
                                          VerticalAlignment="Bottom" 
                                          HorizontalAlignment="Right"
                                          Margin="0,20,0,0"
                                          Command="{Binding SelectOfferCommand}"/&gt;
                          &lt;/StackPanel&gt;
                          &lt;/wpf:Card&gt;
  
                      &lt;/DataTemplate&gt;
                  &lt;/ItemsControl.ItemTemplate&gt;
              &lt;/ItemsControl&gt;
  </code></pre>
  
  <p>This produces a bunch of repeated boxes, every has a button. Every time i click the button i want to access current box index (from ItemsControl's ItemsSource) and pass it as a command parameter. Is it possible to do it?</p>