The code I\'ve written is supposed to overwrite over the contents of the selected text file, but it\'s appending it. What am I doing wrong exactly?
File fnew
Add one more line after initializing file object
File fnew = new File("../playlist/" + existingPlaylist.getText() + ".txt"); fnew.createNewFile();