private void deleteBtnActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_deleteBtnActionPerformed
        // TODO add your handling code here:
        int index = paymentList.getSelectedIndex();
        try {
            String stuID = payingStudent.getStudentID();
            String payID = listPay.get(index);
            if(!stuID.equals("")||!payID.equals("")){
                int x = JOptionPane.showConfirmDialog(this, "Are you sure you want to delete this Payment :\n"+stuID+"\n"+payID);
                
                if(x == 0 ){
                   int y =payControl.deleteOneMonthPaymentRecord(stuID, payID);
                   if(y == 1){
                       JOptionPane.showMessageDialog(this, "Successfully Deleted");
                       clearBtnActionPerformed(evt);
                   }
                   
                   else{
                       JOptionPane.showMessageDialog(this, "Delete was not Success!");
                   }
                  
                }
                
            }
            
        } catch (ClassNotFoundException | SQLException ex) {
            Logger.getLogger(DeleteMonthPay.class.getName()).log(Level.SEVERE, null, ex);
        }
        
        
    }//GEN-LAST:event_deleteBtnActionPerformed