@Override
	public void actionPerformed(ActionEvent e) {
		if (e.getActionCommand().equals(EditStudentPanel.CHOOSE_STUDENT_FOR_EDIT)) {
			this.editStudent(((Student)this.getStudentListModel
					().getElementAt(this.getStudentList().getSelectedIndex())));
		}
		else if (e.getActionCommand().equals(EditStudentPanel.SAVE_STUDENT_INFO)) {
			this.getStudentInfoFields().extractStudentInfo(this.selectedStudent);
		}
		else if (e.getActionCommand().equals(EditStudentPanel.CANCEL_STUDENT_INFO)) {
			((CardLayout)this.getLayout()).show(this, EditStudentPanel.STUDENT_LIST);
		}
		else if (e.getActionCommand().equals(CANCEL_STUDENT_LIST)) {
			((CardLayout)this.getLayout()).show(this, EditStudentPanel.FIND_STUDENT);
		}
		else if (e.getActionCommand().equals(FIND_STUDENTS_BY_NAME_FOR_EDIT)) {
			String firstName = this.getFirstNameTextField().getText().trim();
			String lastName = this.getLastNameTextField().getText().trim();
			List<Student> foundStudents =
				SDTDomainLogic.getSDTDomainLogic().findStudentsByNameForEdit(firstName, lastName);
			// logic to check whether there are any results
			if (foundStudents.size() == 0) {
				JOptionPane.showMessageDialog(this, "No students found");
			}
			TG8ListModel<Student> lm = this.getStudentListModel();
			lm.clear();
			for (Student s : foundStudents ) {
				lm.add(s);
			}
			((CardLayout)this.getLayout()).show(this, STUDENT_LIST);
		}
	}