private void btnEdit_Click(object sender, System.EventArgs e) { var row = dataGridView1.SelectedRows[0].DataBoundItem as Places; var form = new EditPlace(repository, row); form.ShowDialog(); Reload(); }
private void ListViewItemMouseDoubleClick(object sender, MouseButtonEventArgs e) { e.Handled = true; Place place = ((ListViewItem)sender).Content as Place; EditPlace ep = new EditPlace(place, m_wd); ep.ShowDialog(); m_wd.PlaceDatas.PlaceSelected = null; m_wd.PlaceDatas.PlaceSelected = place; }