giving a new file the attributes of an old one

Quote
mbrei...@renoz.ping.dk (Mikkel Breiler) wrote:
>Hello All!
>I have trouble using SETFATTR and SETFTIME with the data of an old file, it is
>as if it doen't get written to disk.
>A summary of the code I use is:
>I serach for the file by the name I have, using FINDFIRST(Info1). I then
>proceed to copy that file into a new file. and I close it. After that I call
>SETFATTR and SETFTIME like this:
>SETFATTR(Info1.Attr);
>SETFTIME(Info1.Time);
>However it doesn't seem to be doing it. Am i dealing with a bug or am I missing
>something obvious?

before you use the SET***-Command you must take a RESET(f) otherwise,
CLOSE(f) will update time and attributes.

begin
  assign(f,'TEST.TXT');
  rewrite(f);
  reset(f);
  SETFTIME(f,Info1.Time);
  close(f);
end.

So long,
        Manfred Hauser