//Edit private void _mainViewModel_StartingMovieEdit(object sender, EventArgs e) { _movieEditorView = new MovieEditorWindow { DataContext = _mainViewModel }; _movieEditorView.ShowDialog(); }
public void OpenEditor(Movie movie) { try { if (movie != null) { repository.GetMovieDetails(movie); movie = movie.Clone(); } var editor = new MovieEditorWindow(movie); var result = editor.ShowDialog(); if (result.HasValue && result.Value) { RetrieveData(); } } catch (Exception ex) { MessageBox.Show(ex.Message); } }