private void Button_Click(object sender, RoutedEventArgs e) { viewModel.AddPerson(); var addPerson = new AddPerson(); Application.Current.MainWindow.Opacity = 0.5; addPerson.Closed += AddPerson_Closed; addPerson.Owner = this; addPerson.vm = viewModel; addPerson.ShowDialog(); }
private void AddButton_Click(object sender, RoutedEventArgs e) { AddPerson addPerson = new AddPerson(); addPerson.ShowDialog(); }