private void dgvCustomer_SelectionChanged(object sender, SelectionChangedEventArgs e) { var d = dgvCustomer.SelectedItem as BLL.Customer; if (d != null) { data.Find(d.Id); } }