Home |
Function RTFSetFileTime |
Function RTFSetFileTimeRTFSetFileTime sets the date and time of last modification in a file's directory entry: int RTFSetFileTime(RTFHANDLE File, const RTFDOSDateTime * Time); ParametersFileReferences the open file for which to set the time and date. TimeMust point to a filled structure RTFDOSDateTime declared in Rtfiles.h: typedef struct { UINT Second2:5; UINT Minute:6; UINT Hour:5; UINT Day:5; UINT Month:4; UINT Year1980:7; } RTFDOSDateTime; Seconds2 holds the seconds part of the desired time divided by 2. Year1980 holds the year part of the desired date minus 1980. The meaning of all other fields is self-explanatory. return valueIf the function succeeds, the return value is RTF_NO_ERROR. If the function fails, the return value is a negative error code. RTFiles-32 will update the file's date and time on every write access. Thus, function RTFSetFileTime should not be followed by a call to RTFWrite, since this would overwrite the date and time set by RTFSetFileTime.
|