title: How to get list item index when user clicks on the button which is in list item in windows phone 8
body: <p>I've list box in my application.
  Below is the screen shot.</p>
  
  <p><img src="https://i.stack.imgur.com/TQSHx.png" alt="enter image description here"></p>
  
  <p><strong>When user clicks on the list item, then i'm displaying detailed page.
  It is handling in below selection changed listener.</strong></p>
  
  <pre><code>private void companiesList_SelectionChanged(object sender, SelectionChangedEventArgs e)
      {            
              //get the selected item from list
              Company selectedItem = (Company)e.AddedItems[0];
  
       Uri uri = new Uri("/CompanyDetailsPage.xaml", UriKind.Relative);
              //navigate to target page
              this.NavigationService.Navigate(uri);
  
              FrameworkElement root = Application.Current.RootVisual as FrameworkElement;
              root.DataContext = selectedItem;
  }
  }
  </code></pre>
  
  <p>Upto this it is fine.</p>
  
  <p><strong>Now when the user clicks on the Delete button which is on the item,
  then i've to delete that item from the list.</strong></p>
  
  <pre><code>private void Del_Btn_clicked(object sender, RoutedEventArgs e)
      {
          //get the Corresponding item from list i.e. On which delete button is placed.
      //Delete saved company from the database   
  
  
      }
  </code></pre>
  
  <p>I'm unable to get that particular list item index on which the delete button is placed.
  Ho could I get.</p>
  
  <p>Thanks.</p>