Having problems reading from and deleting certain lines from a file?
The point of this program is to remove certain sports teams and their members from a text file, then overwrite the original file with the new set of values. This is attempted by reading the values into an array, then looping through the array and deleting the name of the team and the next 2 lines but for some reason it stops going through the array after the index. I'm stuck, so any help would be great Code: private void RemoveSportsTeamButtonActionPerformed(java.awt.event.ActionEvent evt) { String ChosenTeam = ""; ChosenTeam = JOptionPane.showInputDialog("What Team Do you want to remove?");