/// <summary> /// Handling controls /// </summary> //private void lvDepartments_MouseDoubleClick(object sender, System.Windows.Input.MouseButtonEventArgs e) //{ // new WinDepEdt(lvDepartments.SelectedItem as Department).ShowDialog(); // //WinDepartmentEdit.btnAddDep.IsEnabled = "False"; //} private void lvEmployee_MouseDoubleClick(object sender, MouseButtonEventArgs e) { WinEmployeeEdit wee = new WinEmployeeEdit(lvEmployees.SelectedItem as Employee); wee.ShowDialog(); wee.btnAddEmployee.IsEnabled = false; }
private void btnAddEmployee_Click(object sender, RoutedEventArgs e) { WinEmployeeEdit wee = new WinEmployeeEdit(new Employee(), Visibility.Visible); wee.Height = 210; wee.ShowDialog(); wee.btnAddEmployee.IsEnabled = false; }