Im not COMPLETELY sure about this, but when you read data from a text file, each line is a seperate variable in an array i.e. if you have 7 lines of text in a file, you will have an array with 7 variables in it.
Therefore, if you want to read line, you need to get the text out of line 6 (remember arrays start at 0 rather than 1).
You can then edit that variable in the array. to put the array back into the file, you need to do a while loop and cycle through all the variables in the array and write them to a file.
Hope this (kinda) helps 🙂