Ich bin auf der suche nach einer schnellen Möglichkeit das Dateidatum (bzw. timestamp) zu ermitteln. Bisher habe ich diese Routine benutzt
Code: Alles auswählen
Procedure GetFileDate(file$); - Get the time of a File
handle=CreateFile_(@file$,#GENERIC_READ,#FILE_SHARE_READ|#FILE_SHARE_WRITE,0,#OPEN_EXISTING,#FILE_ATTRIBUTE_NORMAL,0)
If handle<>#INVALID_HANDLE_VALUE
GetFileTime_(handle,0,0,FT.FILETIME)
;Result=FileTimeToDate(FT)
CloseHandle_(handle)
FileTimeToLocalFileTime_(FT.FILETIME,FT2.FILETIME)
FileTimeToSystemTime_(FT2,st.SYSTEMTIME)
ProcedureReturn Date(st\wYear,st\wMonth,st\wDay,st\wHour,st\wMinute,st\wSecond)
Else
ProcedureReturn 0
EndIf
EndProcedure
Beispiel: Scan C:
Über die Readdir() - Funktion (CodeArchiv), Nur Name und Größe eingelesen:
ca. 55000 Dateien: 850 ms
zusätzlich Dateidatum über obige Proc: ...abgebrochen nach 30 Sekunden...
Jemand dafür eine Lösung?
ein DirectoryEntrySize und DirectoryEntryAttribute gibts, aber ein DirectoryEntryDate nicht (laut Help)
