浏览代码

* also display time with findfirst

peter 24 年之前
父节点
当前提交
ac372ae559
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3 1
      tests/test/tdos.pp

+ 3 - 1
tests/test/tdos.pp

@@ -78,6 +78,7 @@ end;
 procedure TestDisk;
 var
   Dir : SearchRec;
+  DT  : DateTime;
 begin
   writeln;
   writeln('Disk Functions');
@@ -96,7 +97,8 @@ begin
   FindFirst('*.*',$20,Dir);
   while (DosError=0) do
    begin
-     Writeln(dir.Name,' ',dir.Size);
+     UnpackTime(dir.Time,DT);
+     Writeln(dir.Name,' ',dir.Size,' ',DT.Year,'-',DT.Month,'-',DT.Day);
      FindNext(Dir);
    end;
   write('Press Enter');