Creating and editing a text file

Im trying to get the arduino to edit a txt file on an hdd through the computer.

In that case, all the Arduino will do is send data through serial. You'll need something running on the computer to do the file work.