@Override
    public void actionPerformed(ActionEvent e) {
        if (ImportWords.getSelectedSection() != null) {
            JFileChooser fileChooser = new JFileChooser();
            fileChooser.setFileFilter(new FileNameExtensionFilter("Excel file", "xls"));
            int res = fileChooser.showDialog(null, "Select excel file");
            if (res == JFileChooser.APPROVE_OPTION) {
                File file = fileChooser.getSelectedFile();
                try {
                    if (getWordsFromExcel(file) && exportWordsToDB()) {
                        statusLbl.setText(importedWordsAmout + " words were imported in " +
                                ImportWords.getSelectedSection() + " section");
                    }
                    else {
                        statusLbl.setText("File cannot be imported or such words are already in DB");
                    }
                } catch (SQLException e1) {
                    e1.printStackTrace();
                }
            }
        }
    }