示例#1
0
 private void ShowAnimalButton_Click(object sender, RoutedEventArgs e)
 {
     if (animalListView.SelectedItems.Count > 0)
     {
         Animal     selectedAnimal = (Animal)animalListView.SelectedItems[0];
         AnimalInfo animalInfo     = new AnimalInfo(selectedAnimal.passportId);
         animalInfo.Show();
     }
 }
示例#2
0
 private void showAnimal_Click(object sender, RoutedEventArgs e)
 {
     if (adoptionListView.SelectedItems.Count > 0)
     {
         int        passportId = (int)adoptionListView.SelectedValue;
         AnimalInfo animalInfo = new AnimalInfo(passportId);
         animalInfo.Show();
     }
 }