@faz808 You can get file length by checking len(fileHandle). It's not documented, as far as I know, but len() treats the file just like it treats a string or an array. Note that you can't delete characters from a file, only overwrite, so the file length may not tell you how much usable data is actually in the file. My suggestion is to pick a particular unicode character to represent unallocated file space, use that character to overwrite any data you want to delete from the file, and then search for that character to find the end of the valid data within the file.