private void Modify_btn_Click(object sender, RoutedEventArgs e) { Contract contract = (Contract)contract_list_box.SelectedItem; if (contract != null) { EditWindow ew = new EditWindow(); ew.SetData(contract); ew.ShowDialog(); } }
private void AddContract_Click(object sender, RoutedEventArgs e) { try { EditWindow editWindow = new EditWindow { Owner = this }; editWindow.ShowDialog(); } catch (Exception ex) { Log.E("", "show add contract window error:" + ex.Message); } }