private void MovieAddButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_MovieAddButtonActionPerformed
        boolean startCapital;
        String updateDB;
        boolean isWordName = true;
        boolean isWordDesc = true;
        String movieName = MovieTitleATextField.getText();
        String movieGenre = MovieGenreTextField.getText();
        String movieDesc = MovieGenreTextField.getText();

        isWordName = Pattern.compile("[A-Z].*").matcher(movieName).matches();
        isWordDesc = Pattern.compile("[A-A].*").matcher(movieDesc).matches();

        if (isWordDesc && isWordName) {
            out.println("3!" + movieName + "!" + movieGenre + "!" + movieDesc);

            try {
                updateDB = in.readLine();

                startCapital = Pattern.compile("[A-Z].*").matcher(movieName).matches();
                if (!startCapital) {
                    JOptionPane.showMessageDialog(null, "Movie must start with a capital letter.", "Error", 0);
                }

                if (updateDB.equals("0")) {
                    JOptionPane.showMessageDialog(null, "The movie has been successfully added.", "Message", 1);
                } else if (updateDB.equals("1")) {
                    JOptionPane.showMessageDialog(null, "The movie already exists", "Message", 0);
                } else {
                    JOptionPane.showMessageDialog(null, "The genre does not exist.", "message", 0);
                }
            } catch (IOException e) {
                JOptionPane.showMessageDialog(null, e, "Error", 0);
            }
        } else {
            JOptionPane.showMessageDialog(null, "Genre or Description field left blank", "Message", 0);
        }
    }//GEN-LAST:event_MovieAddButtonActionPerformed