uses
SysUtils
function GetFileDateTime(FileName: string): TDateTime;
var
intFileAge: LongInt;
begin
intFileAge := FileAge(FileName);
if intFileAge = -1 then
Result := 0
else
Result := FileDateToDateTime(intFileAge)
end;
原文:http://www.cnblogs.com/sensor/p/3910350.html