private void btnEdit_Click(object sender, RoutedEventArgs e) { PaSViewModel pas = (PaSViewModel)ViewModel; if ((ProblemVO) lstProblems.SelectedItem != null) { int problemId = ((ProblemVO) lstProblems.SelectedItem).ProblemID; WizardViewModel wvm = new WizardViewModel(null); wvm.InitializeEdit(problemId); new WizardView(wvm).ShowDialog(); pas.RefreshProblemList(); } }
public WizardView(WizardViewModel wizardViewModel) { InitializeComponent(); DataContext = wizardViewModel; }