private void OKActionPerformed( java.awt.event.ActionEvent evt) { // GEN-FIRST:event_OKActionPerformed String invoice = InvoiceTF.getText().trim(); String description = DescriptionArea.getText(); String other = ""; int amount = 0; if (invoice.trim().equals("")) { JOptionPane.showMessageDialog( null, "Please insert the invoice text field! ", "Warning", JOptionPane.WARNING_MESSAGE); InvoiceTF.requestFocusInWindow(); return; } try { amount = Integer.parseInt(AmountTF.getText()); } catch (NumberFormatException nfe) { JOptionPane.showMessageDialog( null, "Please insert the amount text field " + "with number! ", "Warning", JOptionPane.WARNING_MESSAGE); AmountTF.requestFocusInWindow(); return; } // edit other income transaction // other income transaction other = ""; boolean result = tr.OthersIncomeTransaction( invoice, new java.sql.Date(OtherDateChooser.getDate().getTime()), amount, description); if (transactionsEP != null && result) { HTMLEditorManipulation htmlem = new HTMLEditorManipulation(transactionsEP, conn); htmlem.HTMLIncomeDialog(InvoiceTF.getText().trim()); } dispose(); } // GEN-LAST:event_OKActionPerformed