private void donebutton2MouseClicked(java.awt.event.ActionEvent evt) throws SQLException {//GEN-FIRST:event_donebutton2MouseClicked
        // TODO add your handling code here:

        //Check title
    	String bank = namefield.getText().toString();
		String add = addressfield.getText().toString();
		String accnum = accountfield.getText().toString();
		String rou_bal = routingfield.getText().toString();
		String acctype = acctypefield.getText().toString();
		Boolean done = true;


    	if(bank.length() == 0)
    	{
    		JOptionPane.showMessageDialog(null,"Please enter a bank name!");
    		return;
    	}
    	else if(add.length() == 0)
    	{
    		JOptionPane.showMessageDialog(null,"Please enter an address");
    		return;
    	}
    	else if(accnum.length() == 0)
    	{
    		JOptionPane.showMessageDialog(null,"Please enter an account number");
    		return;
    	}
    	else if(rou_bal.length() == 0)
    	{
    		JOptionPane.showMessageDialog(null,"Please enter a routing number");
    		return;
    	}
    	else if(acctype.length() == 0)
    	{
    		JOptionPane.showMessageDialog(null,"Please enter an account type");
    		return;
    	}

    	if(!isUpdating){
    		int result = helpers.newBank(bank, accnum, rou_bal, add, acctype);
    		if(result == -1)
    		{
    			JOptionPane.showMessageDialog(null,"An entry with the given account number already exists");
    			return;
    		}

    		done = true;
    	}
    	else
    	{
    		if( helpers.updateBank(data_id, bank, accnum, rou_bal, add, acctype) == -1 ) {
            	JOptionPane.showMessageDialog(null, "There was an issue updating the database.");
	            done = false;
	        } else {
	            done = true;
	        }
    	}


    	if(done == true)
    	{
    		//new UserAccount(helpers).setVisible(true);

    		//dispose
    		parent.refreshBanksList();
    		dispose();
    	}
    }//GEN-LAST:event_donebutton2MouseClicked