- 4.24.2.30 -
Standard Units
Dos Unit
Dos Unit Procedures and FunctionsSetFTime procedure
Targets: MS-DOS, OS/2, Win32
Dos Unit, WinDos Unit
Sets the date and time a file was last written.
Declaration:
procedure SetFTime(var F; Time: Longint);
The file associated with F must be open. A packed date and time stamp
can be created with PackTime.
Errors are reported in DosError, a variable defined in the Dos unit.
For more information about a file's packed date and time stamp consult
your DOS reference manual.
Win32 target:
The file handle must have been created with GENERIC_WRITE access.
Example:
uses
Dos;
var
Fi : Text;
DT : DateTime;
Time: Longint;
begin
Assign(Fi, 'FUTURE.DOC');
Reset(Fi);
with DT do begin
Year := 2010;
Month := 3;
Day := 31;
Hour := 2;
Min := 45;
Sec := 22;
end;
PackTime(DT, Time);
SetFTime(Fi, Time);
Close(Fi);
end.
|
|
|
SetFAttr procedure |
Table of Content |
SetIntVec procedure |
- 4.24.2.30 -