RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TDateTime::FileDateToDateTime Method

Converts an OS timestamp value to System::TDateTime::TDateTime value.

Pascal
function FileDateToDateTime(fileDate: Integer): TDateTime; static;
C++
static __fastcall TDateTime FileDateToDateTime(int fileDate);

A timestamp is a signed 32-bit integer, used by the OS to record information such as the date and time a file was modified. The precise format of a timestamp depends on the OS. Use System::TDateTime::FileDateToDateTime to convert a timestamp to a System::TDateTime::TDateTime value.  

For example, use System::TDateTime::FileDateToDateTime to convert the file timestamp returned by FileGetDate or FileAge. You may also need to use System::TDateTime::FileDateToDateTime to convert the Time field of the TSearchRec struct used by the FindFirst and FindNext functions. 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!