- #1
dacruick
- 1,042
- 1
Hi, I have a program which is reading in line by line information, saving that, and writing it out to a file. How do I change where the files are created? Also, can I create a folder to write the files out to in my program?
The second issue I have is this. right now my program opens the file, reads a line, writes a line, reads a line, writes a line, until its finished. I want it to read all of the lines, then open the file, then write all of them. Would I save all my lines to an array then fout.write(array[0:x],'w')??
The second issue I have is this. right now my program opens the file, reads a line, writes a line, reads a line, writes a line, until its finished. I want it to read all of the lines, then open the file, then write all of them. Would I save all my lines to an array then fout.write(array[0:x],'w')??
Last edited: