I would guess that would cause only the first line to be written...the output variable is closed on the first loop - that must be moved outside as well. And for future reference, please wrap your...
Type: Posts; User: copeg
I would guess that would cause only the first line to be written...the output variable is closed on the first loop - that must be moved outside as well. And for future reference, please wrap your...
Each time you open the FileWriter, it will overwrite the previous contents. Either open the File outside the loop, or take a look at the API - in particular the constructor that accepts a boolean...