private void editTeamButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_editTeamButtonActionPerformed
        // TODO add your handling code here:

        try {
            //Get the selected team from the list
            int selected = teamList.getSelectedIndex();

            teamNameReader set = new teamNameReader();
            ArrayList<TeamObject> read = null;
            try {
                read = set.readTeamNameObject();
            } catch (ClassNotFoundException ex) {
                Logger.getLogger(teamsListFrame.class.getName()).log(Level.SEVERE, null, ex);
            }

            editTeamsFrame frame = null;
            try {
                frame = new editTeamsFrame(read.get(selected).getTeamNumb(), read.get(selected).getTeamLetter());
            } catch (ClassNotFoundException ex) {
                Logger.getLogger(teamsListFrame.class.getName()).log(Level.SEVERE, null, ex);
            }
            frame.setSize(this.getWidth(), getHeight());
            frame.setLocation(this.getX(), this.getY());
            frame.setVisible(true);
            this.dispose();
        } catch (Exception e) {
            JOptionPane.showMessageDialog(this, "Please Select a Team From the List", "ERROR", JOptionPane.ERROR_MESSAGE);
        }

    }//GEN-LAST:event_editTeamButtonActionPerformed