so, why not just use readfile() and then writefile()

nah, even easier, readline() + drop-the-last-lines-code + writeline()
_________________________
!

download KiXnet