Subj : Re: a problem To : Thomas W. Mueller From : Scott Adams Date : Sat Jun 02 2001 03:54 pm -=> Quoting Thomas W. Mueller to Scott Adams <=- NM>> assign(a,'telefoni.dat'); NM>> reset(a); NM>> write(a,novi); NM>> close(a); TWM>> The above ist basically what you are doing. You open a file for TWM>> reading and then try to write to it. Unless you set the file TWM>> access to readwrite this will not work. Unfortunately I don't TWM>> quite recall how to do that. I think there is a variable TWM>> somewhere that you must set: FileMode It should be described in TWM>> the online help. SA> Would use Rewrite() rather than Reset() TWM> Maybe I should not have cut out so much of the original code. He was TWM> first reading from the file and then writing back to it. In order to TWM> open a file in read/write mode, you must use Reset, not Rewrite. TWM> Rewrite would truncate the existing file, deleting all the data in it. Yep. I wasn't sure if he wanted it appended or new file. I've actually never touched the fileMode stuff except I think once in 18+ years doing pascal...that was for a bbs util I think that required it. Course back in pascal 3 you had to use it alot... .... U'll no fear. U'll no pain. And then U'll die. Have a nice flight! --- Fringe BBS * Origin: EWOG II - The Fringe - 904-733-1721 (1:112/91) .