Quote:
If you want to delete the final newline from a text file, what I suggested will work

On the other hand, maybe you're confused about the trailing newline and you think it's not supposed to be there. It is. Are you having a problem with the CSV file that makes it look like you have an extra blank line?


The file is submitted via an upload process and the last LF makes it unreadable for those purposes, the program that reads in the uploaded file can't deal with an extra LF at the end of the file (HM Customs & Excise)

Thanks so far